You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/iot-operations/develop-edge-apps/quickstart-get-started-sdks.md
+91-25Lines changed: 91 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,14 +27,7 @@ Before you begin, prepare the following prerequisites:
27
27
28
28
Developing with the Azure IoT Operations SDKs requires a Kubernetes cluster with Azure IoT Operations deployed. Additional configuration will allow MQTT broker to be accessed directly from the developer environment. The following development environment setup options use [k3d](https://k3d.io/#what-is-k3d) to simplify Kubernetes cluster creation. Codespaces provides the most streamlined experience and can get the development environment up and running in a couple of minutes.
29
29
30
-
Follow the steps in **one of the sections** below to get your development environment up and running:
*[Option 3 - **Linux devcontainer on Windows**](#option-3---linux-devcontainer-on-windows)
35
-
*[Option 4 - **Windows Subsystem for Linux**](#option-4---windows-subsystem-for-linux)
36
-
37
-
### Option 1 - Codespaces
30
+
### [Codespaces](#tab/codespaces)
38
31
39
32
> [!CAUTION]
40
33
> We are currently experiencing container corruption with Azure IoT Operations deployed in a codespace, so we don't recommend this path until we have resolved the issue with the GitHub team.
@@ -45,7 +38,7 @@ Follow the steps in **one of the sections** below to get your development enviro
45
38
46
39
1. Once the codespace is created, you will have a container with the developer tools and a local k3s cluster pre-installed.
1. Launch a shell, and change to the root directory of the *Azure IoT Operations SDKs* repository.
53
+
1. Change to the repository root directory:
54
+
55
+
```bash
56
+
cd<REPOSITORY ROOT>
57
+
```
61
58
62
-
1. Initialize the cluster and install required dependencies:
59
+
1. Initialize the cluster and install required dependencies using the `initialize-cluster.sh` script:
63
60
64
61
```bash
65
62
sudo ./tools/deployment/initialize-cluster.sh
66
63
```
67
64
68
-
### Option 3 - Linux devcontainer on Windows
65
+
### [Visual Studio Code Dev Containers](#tab/vscode-dev-containers)
69
66
70
67
> [!WARNING]
71
68
> The latest WSL release **doesn't support Azure IoT Operations**. You will need to install [WSL v2.3.14](https://github.com/microsoft/WSL/releases/tag/2.3.14) as outlined in the steps below.
@@ -96,9 +93,13 @@ Follow the steps in **one of the sections** below to get your development enviro
96
93
https://github.com/azure/iot-operations-sdks
97
94
```
98
95
99
-
1. Launch a shell, and change to the root directory of the *Azure IoT Operations SDKs* repository.
96
+
1. Change to the repository root directory:
100
97
101
-
1. Initialize the cluster and install required dependencies:
98
+
```bash
99
+
cd<REPOSITORY ROOT>
100
+
```
101
+
102
+
1. Initialize the cluster and install required dependencies using the `initialize-cluster.sh` script:
102
103
103
104
```bash
104
105
sudo ./tools/deployment/initialize-cluster.sh
@@ -108,7 +109,7 @@ Follow the steps in **one of the sections** below to get your development enviro
108
109
> [!TIP]
109
110
> To reconnect to the container in VSCode, choose `F1 > Dev Containers: Attach to Running Container...` and thenselectthe container name created previously.
110
111
111
-
### Option 4 - Windows Subsystem for Linux
112
+
### [Windows Subsystem for Linux (WSL)](#tab/wsl)
112
113
113
114
> [!WARNING]
114
115
> The latest WSL release **doesn't support Azure IoT Operations**. You will need to install [WSL v2.3.14](https://github.com/microsoft/WSL/releases/tag/2.3.14) as outlined in the steps below.
@@ -133,31 +134,88 @@ Follow the steps in **one of the sections** below to get your development enviro
Azure IoT Operations will be installed to the development cluster, and then the configuration will be altered to provide additional off-cluster access methods to streamline development:
154
+
Azure IoT Operations will be deployed on the development cluster that you created in the previous step, and then the configuration will be altered with the `configure-aio.sh` script to provide additional off-cluster access methods to streamline development:
149
155
150
-
1. Follow the [Azure IoT Operations documentation](https://learn.microsoft.com/azure/iot-operations/get-started-end-to-end-sample/quickstart-deploy?tabs=codespaces#connect-cluster-to-azure-arc) to connect Azure Arc and deploy Azure IoT Operations.
156
+
### [Codespaces](#tab/codespaces)
151
157
152
-
1. Check that Azure IoT Operations is successfully installed and **Resolve any errors before continuing**:
158
+
1. Follow the instructions in [Quickstart: Run Azure IoT Operations in GitHub Codespaces with K3s](../get-started-end-to-end-sample/quickstart-deploy.md#connect-cluster-to-azure-arc) to connect your cluster to Azure Arc, create a storage account and schema registry, and deploy Azure IoT Operations.
153
159
154
-
```bash
160
+
[!NOTE]
161
+
> The Codespaces environment already has the cluster created, so you can skip the **Create cluster** step in the quickstart.
162
+
163
+
### [Ubuntu](#tab/ubuntu)
164
+
165
+
1. Create an Azure resource group. Only one Azure IoT Operations instance is supported per resource group. To create a new resource group, use the [az group create](/cli/azure/group#az-group-create) command. For the list of currently supported Azure regions, see [Supported regions](../overview-iot-operations.md#supported-regions).
166
+
167
+
```azurecli
168
+
az group create --location <REGION> --resource-group <RESOURCE_GROUP> --subscription <SUBSCRIPTION_ID>
169
+
```
170
+
171
+
1. Follow the instructions in [Prepare your Azure Arc-enabled Kubernetes cluster](../deploy-iot-ops/howto-prepare-cluster.md#arc-enable-your-cluster) to arc-enable your cluster in Ubuntu.
172
+
173
+
1. Follow the instructions in [Deploy Azure IoT Operations to an Arc-enabled Kubernetes cluster](../deploy-iot-ops/howto-deploy-iot-operations.md) to deploy Azure IoT Operations to your cluster.
174
+
175
+
[!NOTE]
176
+
> You can start with test settings, and then [enable secure settings](../deploy-iot-ops/howto-enable-secure-settings.md) later.
177
+
178
+
### [Visual Studio Code Dev Containers](#tab/vscode-dev-containers)
179
+
180
+
1. Create an Azure resource group. Only one Azure IoT Operations instance is supported per resource group. To create a new resource group, use the [az group create](/cli/azure/group#az-group-create) command. For the list of currently supported Azure regions, see [Supported regions](../overview-iot-operations.md#supported-regions).
181
+
182
+
```azurecli
183
+
az group create --location <REGION> --resource-group <RESOURCE_GROUP> --subscription <SUBSCRIPTION_ID>
184
+
```
185
+
186
+
1. Follow the instructions in [Prepare your Azure Arc-enabled Kubernetes cluster](../deploy-iot-ops/howto-prepare-cluster.md#arc-enable-your-cluster) to arc-enable your cluster in Ubuntu.
187
+
188
+
1. Follow the instructions in [Deploy Azure IoT Operations to an Arc-enabled Kubernetes cluster](../deploy-iot-ops/howto-deploy-iot-operations.md) to deploy Azure IoT Operations to your cluster.
189
+
190
+
[!NOTE]
191
+
> You can start with test settings, and then [enable secure settings](../deploy-iot-ops/howto-enable-secure-settings.md) later.
192
+
193
+
### [Windows Subsystem for Linux (WSL)](#tab/wsl)
194
+
195
+
1. Create an Azure resource group. Only one Azure IoT Operations instance is supported per resource group. To create a new resource group, use the [az group create](/cli/azure/group#az-group-create) command. For the list of currently supported Azure regions, see [Supported regions](../overview-iot-operations.md#supported-regions).
196
+
197
+
```azurecli
198
+
az group create --location <REGION> --resource-group <RESOURCE_GROUP> --subscription <SUBSCRIPTION_ID>
199
+
```
200
+
201
+
1. Follow the instructions in [Prepare your Azure Arc-enabled Kubernetes cluster](../deploy-iot-ops/howto-prepare-cluster.md#arc-enable-your-cluster) to arc-enable your cluster in Ubuntu.
202
+
203
+
1. Follow the instructions in [Deploy Azure IoT Operations to an Arc-enabled Kubernetes cluster](../deploy-iot-ops/howto-deploy-iot-operations.md) to deploy Azure IoT Operations to your cluster.
204
+
205
+
[!NOTE]
206
+
> You can start with test settings, and then [enable secure settings](../deploy-iot-ops/howto-enable-secure-settings.md) later.
207
+
208
+
---
209
+
210
+
1. Check that Azure IoT Operations is successfully installed and **resolve any errors before continuing**:
211
+
212
+
```acurecli
155
213
az iot ops check
156
214
```
157
215
158
216
Expected output:
159
217
160
-
```bash
218
+
```output
161
219
╭─────── Check Summary ───────╮
162
220
│ 13 check(s) succeeded. │
163
221
│ 0 check(s) raised warnings. │
@@ -166,15 +224,23 @@ Azure IoT Operations will be installed to the development cluster, and then the
166
224
╰─────────────────────────────╯
167
225
```
168
226
169
-
1. Run the `configure-aio` script to configure Azure IoT Operations for development:
227
+
1. Change to the repository root directory:
228
+
229
+
```bash
230
+
cd<REPOSITORY ROOT>
231
+
```
232
+
233
+
1. Run the `configure-aio.sh` script to configure Azure IoT Operations for development:
170
234
171
235
```bash
172
236
./tools/deployment/configure-aio.sh
173
237
```
174
238
175
239
## Shell configuration
176
240
177
-
The samples within this repository read configuration from environment variables. We have provided a [.env](/.env) file in the repository root that exports the variables used by the samples to connect to the MQTT Broker.
241
+
The samples within [Azure IoT Operations SDKs github repository](https://github.com/Azure/iot-operations-sdks) read configuration from environment variables. We have provided an `.env` file in the repository root that exports the variables used by the samples to connect to the MQTT Broker. Edit the `.env` file to set the values foryour environment, or use the default values providedin the file.
242
+
243
+
To load the environment variables into your shell, run the following commandin your terminal:
0 commit comments