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/deploy-iot-ops/howto-deploy-iot-operations.md
+74-27Lines changed: 74 additions & 27 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,9 +21,9 @@ Learn how to deploy Azure IoT Operations Preview to a Kubernetes cluster and the
21
21
* Arc extensions
22
22
* Custom locations
23
23
* Resource sync rules
24
-
* Resources that you can configure in your Azure IoT Operations solution, like assets, MQTT broker, and dataflows.
24
+
* Resources that you can configure in your Azure IoT Operations solution, like assetsand asset endpoints.
25
25
26
-
* An Azure IoT Operations *instance* is one part of a deployment. It's the parent resource that bundles the suite of services that are defined in [What is Azure IoT Operations Preview?](../overview-iot-operations.md), like MQ and OPC UA connector.
26
+
* An Azure IoT Operations *instance* is one part of a deployment. It's the parent resource that bundles the suite of services that are defined in [What is Azure IoT Operations Preview?](../overview-iot-operations.md) like MQTT broker, dataflows, and OPC UA connector.
27
27
28
28
In this article, when we talk about deploying Azure IoT Operations we mean the full set of components that make up a *deployment*. Once the deployment exists, you can view, manage, and update the *instance*.
29
29
@@ -33,21 +33,31 @@ Cloud resources:
33
33
34
34
* An Azure subscription.
35
35
36
-
*Azure access permissions. At a minimum, have **Contributor** permissions in your Azure subscription. Depending on the deployment feature flag status you select, you might also need **Microsoft/Authorization/roleAssignments/write** permissions for the resource group that contains your Arc-enabled Kubernetes cluster. You can make a custom role in Azure role-based access control or assign a built-in role that grants this permission. For more information, see [Azure built-in roles for General](../../role-based-access-control/built-in-roles/general.md).
36
+
*An Azure key vault. To create a new key vault, use the [az keyvault create](/cli/azure/keyvault#az-keyvault-create) command:
37
37
38
-
If you *don't* have role assignment write permissions, you can still deploy Azure IoT Operations by disabling some features. This approach is discussed in more detail in the [Deploy](#deploy) section of this article.
38
+
```azurecli
39
+
az keyvault create --enable-rbac-authorization --name "<KEYVAULT_NAME>" --resource-group "<RESOURCE_GROUP>"
40
+
```
39
41
40
-
* In the Azure CLI, use the [az role assignment create](/cli/azure/role/assignment#az-role-assignment-create) command to give permissions. For example, `az role assignment create --assignee sp_name --role "Role Based Access Control Administrator" --scope subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/MyResourceGroup`
42
+
*Azure access permissions:
41
43
42
-
*In the Azure portal, when you assign privileged admin roles to a user or principal, you can restrict access using conditions. For this scenario, select the **Allow user to assign all roles**condition in the **Add role assignment** page.
44
+
*At a minimum, have **Contributor**permissions in your Azure subscription.
43
45
44
-
:::image type="content" source="./media/howto-deploy-iot-operations/add-role-assignment-conditions.png" alt-text="Screenshot that shows assigning users highly privileged role access in the Azure portal.":::
* An Azure key vault that has the **Permission model**set to **Vault access policy**. You can check this setting in the **Access configuration** section of an existing key vault. To create a new key vault, use the [az keyvault create](/cli/azure/keyvault#az-keyvault-create) command:
48
+
* The following tasks require **Microsoft/Authorization/roleAssignments/write**permissions. You can make a custom role in Azure role-based access control or assign a [built-in role](../../role-based-access-control/built-in-roles/general.md) that grants this permission.
47
49
48
-
```azurecli
49
-
az keyvault create --enable-rbac-authorization false --name "<KEYVAULT_NAME>" --resource-group "<RESOURCE_GROUP>"
50
-
```
50
+
* Enabling resource sync rules on the Azure IoT Operations instance. If you don't have role assignment write permissions, you can disable this feature during deployment. This approach is discussed in more detail in the [Deploy](#deploy) section of this article.
51
+
52
+
* Creating a schema registry. If you don't have role assignment write permissions, you can request them or ask that someone with the correct permissions create a schema registry that you can refer to.
53
+
54
+
> [!TIP]
55
+
>
56
+
> * If you use the Azure CLI, use the [az role assignment create](/cli/azure/role/assignment#az-role-assignment-create) command to give permissions. For example, `az role assignment create --assignee sp_name --role "Role Based Access Control Administrator" --scope subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/MyResourceGroup`
57
+
>
58
+
> * If you use the Azure portal to assign privileged admin roles to a user or principal, you're prompted to restrict access using conditions. For this scenario, select the **Allow user to assign all roles** condition in the **Add role assignment** page.
59
+
>
60
+
> :::image type="content" source="./media/howto-deploy-iot-operations/add-role-assignment-conditions.png" alt-text="Screenshot that shows assigning users highly privileged role access in the Azure portal.":::
51
61
52
62
Development resources:
53
63
@@ -61,7 +71,7 @@ Development resources:
61
71
62
72
A cluster host:
63
73
64
-
* An Azure Arc-enabled Kubernetes cluster. If you don't have one, follow the steps in [Prepare your Azure Arc-enabled Kubernetes cluster](./howto-prepare-cluster.md?tabs=wsl-ubuntu).
74
+
* An Azure Arc-enabled Kubernetes cluster with the custom location and workload identity features enabled. If you don't have one, follow the steps in [Prepare your Azure Arc-enabled Kubernetes cluster](./howto-prepare-cluster.md?tabs=wsl-ubuntu).
65
75
66
76
If you deployed Azure IoT Operations to your cluster previously, uninstall those resources before continuing. For more information, see [Update Azure IoT Operations](#update-azure-iot-operations).
67
77
@@ -142,33 +152,70 @@ The Azure portal deployment experience is a helper tool that generates a deploym
142
152
| Parameter | Value |
143
153
| --------- | ----- |
144
154
|**Azure IoT Operations name**|*Optional*: Replace the default name for the Azure IoT Operations instance. |
145
-
|**MQTT broker configuration**|*Optional*: Replace the default settings for the MQTT broker. For more information, see [Configure core MQTT broker settings](../manage-mqtt-broker/howto-configure-availability-scale.md). |
155
+
|**MQTT broker configuration**|*Optional*: Edit the default settings for the MQTT broker. For more information, see [Configure core MQTT broker settings](../manage-mqtt-broker/howto-configure-availability-scale.md). |
156
+
|**Dataflow profile configuration**|*Optional*: Edit the default settings for dataflows. For more information, see [Configure dataflow profile](../connect-to-cloud/howto-configure-dataflow-profile.md). |
146
157
147
-
1. Select **Next: Automation**.
158
+
:::image type="content" source="./media/howto-deploy-iot-operations/deploy-configuration.png" alt-text="A screenshot that shows the second tab for deploying Azure IoT Operations from the portal.":::
159
+
160
+
1. Select **Next: Dependency management**.
161
+
162
+
1. On the **Dependency management** tab, select an existing schema registry or use these steps to create one:
163
+
164
+
1. Select **Create new**.
165
+
166
+
1. Provide a **Schema registry name** and **Schema registry namespace**.
167
+
168
+
1. Select **Select Azure Storage container**.
169
+
170
+
1. Schema registry requires an Azure Storage account with hierarchical namespace and public network access enabled. Choose a storage account from the list of hierarchical namespace-enabled accounts, or select **Create** to create one.
171
+
172
+
1. Select a container in your storage account or select **Container** to create one.
173
+
174
+
1. Select **Apply** to confirm the schema registry configurations.
175
+
176
+
1. On the **Dependency management** tab, select the **Secure settings** deployment option.
148
177
149
-
1. On the **Automation** tab, provide the following information:
178
+
:::image type="content" source="./media/howto-deploy-iot-operations/deploy-dependency-management-1.png" alt-text="A screenshot that shows selecting secure settings on the third tab for deploying Azure IoT Operations from the portal.":::
179
+
180
+
1. In the **Deployment options** section, provide the following information:
150
181
151
182
| Parameter | Value |
152
183
| --------- | ----- |
153
184
|**Subscription**| Select the subscription that contains your Azure key vault. |
154
-
|**Azure Key Vault**| Select your Azure key vault. Or, select **Create new**.<br><br>Ensure that your key vault has **Vault access policy** as its permission model. To check this setting, select **Manage selected vault** > **Settings** > **Access configuration**. |
185
+
|**Azure Key Vault**| Select an Azure key vault select **Create new**.<br><br>Ensure that your key vault has **Vault access policy** as its permission model. To check this setting, select **Manage selected vault** > **Settings** > **Access configuration**. |
186
+
|**User assigned managed identity for secrets**| Select an identity or select **Create new**. |
187
+
|**User assigned managed identity for AIO components**| Select an identity or select **Create new**. Don't use the same managed identity as the one you selected for secrets. |
155
188
156
-
:::image type="content" source="./media/howto-deploy-iot-operations/deploy-automation.png" alt-text="A screenshot that shows the third tab for deploying Azure IoT Operations from the portal.":::
189
+
:::image type="content" source="./media/howto-deploy-iot-operations/deploy-dependency-management-2.png" alt-text="A screenshot that shows configuring secure settings on the third tab for deploying Azure IoT Operations from the portal.":::
157
190
158
-
1.If you didn't prepare your Azure CLI environment as described in the prerequisites, do so now in a terminal of your choice:
191
+
1.Select **Next: Automation**.
159
192
160
-
```azurecli
161
-
az upgrade
162
-
az extension add --upgrade --name azure-iot-ops
163
-
```
193
+
1. One at a time, run each Azure CLI command on the **Automation** tab in a terminal:
164
194
165
-
1. Sign in to Azure CLI interactively with a browser even if you already signed in before. If you don't sign in interactively, you might get an error that says *Your device is required to be managed to access your resource* when you continue to the next step to deploy Azure IoT Operations.
195
+
1. Sign in to Azure CLI interactively with a browser even if you already signed in before. If you don't sign in interactively, you might get an error that says *Your device is required to be managed to access your resource* when you continue to the next step to deploy Azure IoT Operations.
166
196
167
-
```azurecli
168
-
az login
169
-
```
197
+
```azurecli
198
+
az login
199
+
```
200
+
201
+
1. If you didn't prepare your Azure CLI environment as described in the prerequisites, do so now in a terminal of your choice:
202
+
203
+
```azurecli
204
+
az upgrade
205
+
az extension add --upgrade --name azure-iot-ops
206
+
```
207
+
208
+
1. Copy and run the `az iot ops schema registry create` command.
209
+
210
+
1. Copy and run the `az iot ops init` command.
211
+
212
+
1. Copy and run the `az iot ops create` command.
213
+
214
+
1. Copy and run the `az iot ops secretsync enable` command.
215
+
216
+
1. Copy and run the `az iot ops identity assign` command.
170
217
171
-
1.Copy the [az iot ops init](/cli/azure/iot/ops#az-iot-ops-init) command from the **Automation** tab in the Azure portal and run it in your terminal.
218
+
1. Once all of the Azure CLI commands have completed successfully, you can close the **Install Azure IoT Operations** wizard.
Copy file name to clipboardExpand all lines: articles/iot-operations/deploy-iot-ops/howto-prepare-cluster.md
+14-58Lines changed: 14 additions & 58 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,13 +23,13 @@ An Azure Arc-enabled Kubernetes cluster is a prerequisite for deploying Azure Io
23
23
24
24
## Prerequisites
25
25
26
-
Azure IoT Operations should work on any Arc-enabled Kubernetes cluster that meets the [Azure Arc-enabled Kubernetes system requirements](/azure/azure-arckubernetes/system-requirements). Currently Azure IoT Operations doesn't support ARM64 architectures.
26
+
Azure IoT Operations should work on any Arc-enabled Kubernetes cluster that meets the [Azure Arc-enabled Kubernetes system requirements](/azure/azure-arc/kubernetes/system-requirements). Currently Azure IoT Operations doesn't support ARM64 architectures.
27
27
28
28
Microsoft supports AKS Edge Essentials for deployments on Windows and K3s for deployments on Ubuntu. For a list of specific hardware and software combinations that are tested and validated, see [Validated environments](../overview-iot-operations.md#validated-environments).
29
29
30
30
To prepare your Azure Arc-enabled Kubernetes cluster, you need:
31
31
32
-
* Hardware that meets the [system requirements](/azure/azure-arckubernetes/system-requirements).
32
+
* Hardware that meets the [system requirements](/azure/azure-arc/kubernetes/system-requirements).
@@ -254,65 +254,25 @@ To connect your cluster to Azure Arc:
254
254
export CLUSTER_NAME=<NEW_CLUSTER_NAME>
255
255
```
256
256
257
-
1. Set the Azure subscription context for all commands:
258
-
259
-
```azurecli
260
-
az account set -s $SUBSCRIPTION_ID
261
-
```
262
-
263
-
1. Register the required resource providers in your subscription:
264
-
265
-
>[!NOTE]
266
-
>This step only needs to be run once per subscription. To register resource providers, you need permission to do the `/register/action` operation, which is included in subscription Contributor and Owner roles. For more information, see [Azure resource providers and types](../../azure-resource-manager/management/resource-providers-and-types.md).
267
-
268
-
```azurecli
269
-
az provider register -n "Microsoft.ExtendedLocation"
270
-
az provider register -n "Microsoft.Kubernetes"
271
-
az provider register -n "Microsoft.KubernetesConfiguration"
272
-
az provider register -n "Microsoft.IoTOperationsOrchestrator"
273
-
az provider register -n "Microsoft.IoTOperations"
274
-
az provider register -n "Microsoft.DeviceRegistry"
275
-
```
276
-
277
-
1. Download and install a preview version of the `connectedk8s` extension for Azure CLI.
278
-
279
-
```azurecli
280
-
az storage blob download --auth-mode login --blob-url https://github.com/AzureArcForKubernetes/azure-cli-extensions/blob/connectedk8s/public/cli-extensions/connectedk8s-1.10.0-py2.py3-none-any.whl -f ./connectedk8s-1.10.0-py2.py3-none-any.whl
281
-
282
-
az extension add --upgrade --source ./connectedk8s-1.10.0-py2.py3-none-any.whl
283
-
```
284
-
285
-
1. Use the [az group create](/cli/azure/group#az-group-create) command to create a resource group in your Azure subscription to store all the resources:
286
-
287
-
```azurecli
288
-
az group create --location $LOCATION --resource-group $RESOURCE_GROUP --subscription $SUBSCRIPTION_ID
289
-
```
290
-
291
-
1. Use the [az connectedk8s connect](/cli/azure/connectedk8s#az-connectedk8s-connect) command to Arc-enable your Kubernetes cluster and manage it as part of your Azure resource group:
1. Upgrade the Azure Arc agent to use a preview build that supports the workload identity feature that Azure IoT Operations uses for user-assigned managed identities.
1. Get the `objectId` of the Microsoft Entra ID application that the Azure Arc service uses and save it as an environment variable.
263
+
1. In your codespace terminal, sign in to Azure CLI:
302
264
303
265
```azurecli
304
-
export OBJECT_ID=$(az ad sp show --id bc313c14-388c-4e7d-a58e-70017303ee3b --query id -o tsv)
266
+
az login
305
267
```
306
268
307
-
1. Use the [az connectedk8s enable-features](/cli/azure/connectedk8s#az-connectedk8s-enable-features) command to enable custom location support on your cluster. This command uses the `objectId` of the Microsoft Entra ID application that the Azure Arc service uses. Run this command on the machine where you deployed the Kubernetes cluster:
> If you're using the GitHub codespace environment in a browser rather than VS Code desktop, running `az login` returns a localhost error. To fix the error, either:
271
+
>
272
+
> * Open the codespace in VS Code desktop, and then return to the browser terminal and rerun `az login`.
273
+
> * Or, after you get the localhost error on the browser, copy the URL from the browser and run `curl "<URL>"` in a new terminal tab. You should see a JSON response with the message "You have logged into Microsoft Azure!."
A _site_ is a collection of Azure IoT Operations instances. Sites typically group instances by physical location and make it easier for OT users to locate and manage assets. An IT administrator creates sites and assigns Azure IoT Operations instances to them. To learn more, see [What is Azure Arc site manager (preview)?](/azure/azure-arc/site-manager/overview).
366
-
367
323
## Next steps
368
324
369
325
Now that you have an Azure Arc-enabled Kubernetes cluster, you can [deploy Azure IoT Operations](howto-deploy-iot-operations.md).
0 commit comments