Skip to content

Commit ef10314

Browse files
committed
Adding setup and install steps
1 parent ba72c79 commit ef10314

File tree

1 file changed

+91
-25
lines changed

1 file changed

+91
-25
lines changed

articles/iot-operations/develop-edge-apps/quickstart-get-started-sdks.md

Lines changed: 91 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,7 @@ Before you begin, prepare the following prerequisites:
2727

2828
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.
2929

30-
Follow the steps in **one of the sections** below to get your development environment up and running:
31-
32-
* [Option 1 - **Codespaces**](#option-1---codespaces)
33-
* [Option 2 - **Linux**](#option-2---linux)
34-
* [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)
3831

3932
> [!CAUTION]
4033
> 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
4538

4639
1. Once the codespace is created, you will have a container with the developer tools and a local k3s cluster pre-installed.
4740

48-
### Option 2 - Linux
41+
### [Ubuntu](#tab/ubuntu)
4942

5043
1. Install [Ubuntu](https://ubuntu.com/download/desktop)
5144

@@ -57,15 +50,19 @@ Follow the steps in **one of the sections** below to get your development enviro
5750
git clone https://github.com/Azure/iot-operations-sdks
5851
```
5952

60-
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+
```
6158

62-
1. Initialize the cluster and install required dependencies:
59+
1. Initialize the cluster and install required dependencies using the `initialize-cluster.sh` script:
6360

6461
```bash
6562
sudo ./tools/deployment/initialize-cluster.sh
6663
```
6764

68-
### Option 3 - Linux devcontainer on Windows
65+
### [Visual Studio Code Dev Containers](#tab/vscode-dev-containers)
6966

7067
> [!WARNING]
7168
> 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
9693
https://github.com/azure/iot-operations-sdks
9794
```
9895

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:
10097

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:
102103

103104
```bash
104105
sudo ./tools/deployment/initialize-cluster.sh
@@ -108,7 +109,7 @@ Follow the steps in **one of the sections** below to get your development enviro
108109
> [!TIP]
109110
> To reconnect to the container in VSCode, choose `F1 > Dev Containers: Attach to Running Container...` and then select the container name created previously.
110111

111-
### Option 4 - Windows Subsystem for Linux
112+
### [Windows Subsystem for Linux (WSL)](#tab/wsl)
112113

113114
> [!WARNING]
114115
> 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
133134
git clone https://github.com/Azure/iot-operations-sdks
134135
```
135136

136-
1. Launch a shell, and change to the root directory of the *Azure IoT Operations SDKs* repository.
137+
1. Change to the repository root directory:
138+
139+
```bash
140+
cd <REPOSITORY ROOT>
141+
```
137142

138-
1. Initialize the cluster and install required dependencies:
143+
1. Initialize the cluster and install required dependencies using the `initialize-cluster.sh` script:
139144

140145
```bash
141146
sudo ./tools/deployment/initialize-cluster.sh
142147
```
143148

149+
---
144150

145151
<!-- TODO: We will write the steps here instead of pointing to the quickstart -->
146-
## **Install Azure IoT Operations (NEEDS REWRITING)
152+
## Deploy Azure IoT Operations
147153

148-
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:
149155

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)
151157

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.
153159

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
155213
az iot ops check
156214
```
157215

158216
Expected output:
159217

160-
```bash
218+
```output
161219
╭─────── Check Summary ───────╮
162220
│ 13 check(s) succeeded. │
163221
│ 0 check(s) raised warnings. │
@@ -166,15 +224,23 @@ Azure IoT Operations will be installed to the development cluster, and then the
166224
╰─────────────────────────────╯
167225
```
168226

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:
170234

171235
```bash
172236
./tools/deployment/configure-aio.sh
173237
```
174238

175239
## Shell configuration
176240

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 for your environment, or use the default values provided in the file.
242+
243+
To load the environment variables into your shell, run the following command in your terminal:
178244

179245
```bash
180246
source <REPOSITORY ROOT>/.env

0 commit comments

Comments
 (0)