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
Learn how to deploy Azure IoT Operations Preview to a Kubernetes cluster and then manage that Azure IoT Operations instance using the Azure CLI or Azure portal.
17
+
Learn how to deploy Azure IoT Operations Preview to a Kubernetes cluster using the Azure CLI or Azure portal.
18
+
19
+
In this article, we discuss Azure IoT Operations *deployments* and *instances*, which are two different concepts:
18
20
19
21
* An Azure IoT Operations *deployment* describes all of the components and resources that enable the Azure IoT Operations scenario. These components and resources include:
20
22
* An Azure IoT Operations instance
@@ -23,9 +25,9 @@ Learn how to deploy Azure IoT Operations Preview to a Kubernetes cluster and the
23
25
* Resource sync rules
24
26
* Resources that you can configure in your Azure IoT Operations solution, like assets and asset endpoints.
25
27
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.
28
+
* An Azure IoT Operations *instance* is 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
29
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*.
30
+
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
31
30
32
## Prerequisites
31
33
@@ -39,17 +41,17 @@ Cloud resources:
39
41
az keyvault create --enable-rbac-authorization --name "<KEYVAULT_NAME>" --resource-group "<RESOURCE_GROUP>"
40
42
```
41
43
42
-
* Azure access permissions:
44
+
* Azure access permissions. For more information, see [Steps to assign an Azure role](../../role-based-access-control/role-assignments-steps.md).
43
45
44
46
* At a minimum, have **Contributor** permissions in your Azure subscription.
* 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.
50
+
* The following tasks require **Microsoft/Authorization/roleAssignments/write** permissions.
49
51
50
52
* 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
53
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.
54
+
* Creating a schema registry.
53
55
54
56
> [!TIP]
55
57
>
@@ -61,7 +63,7 @@ Cloud resources:
61
63
62
64
Development resources:
63
65
64
-
* Azure CLI installed on your development machine. For more information, see [How to install the Azure CLI](/cli/azure/install-azure-cli). This scenario requires Azure CLI version 2.53.0 or higher. Use `az --version` to check your version and `az upgrade` to update if necessary.
66
+
* Azure CLI installed on your development machine. This scenario requires Azure CLI version 2.64.0 or higher. Use `az --version` to check your version and `az upgrade` to update if necessary. For more information, see [How to install the Azure CLI](/cli/azure/install-azure-cli).
65
67
66
68
* The Azure IoT Operations extension for Azure CLI. Use the following command to add the extension or update it to the latest version:
67
69
@@ -73,11 +75,9 @@ A cluster host:
73
75
74
76
* 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).
75
77
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).
77
-
78
-
Azure IoT Operations should work on any CNCF-conformant kubernetes cluster. Currently, Microsoft only supports K3s on Ubuntu Linux and WSL, or AKS Edge Essentials on Windows.
78
+
If you deployed Azure IoT Operations to your cluster previously, uninstall those resources before continuing. For more information, see [Update Azure IoT Operations](./howto-manage-update-uninstall.md#update).
79
79
80
-
Use the Azure IoT Operations extension for Azure CLI to verify that your cluster host is configured correctly for deployment by using the [verify-host](/cli/azure/iot/ops#az-iot-ops-verify-host) command on the cluster host:
80
+
* Verify that your cluster host is configured correctly for deployment by using the [verify-host](/cli/azure/iot/ops#az-iot-ops-verify-host) command on the cluster host:
81
81
82
82
```azurecli
83
83
az iot ops verify-host
@@ -91,7 +91,7 @@ The Azure portal deployment experience is a helper tool that generates a deploym
91
91
92
92
### [Azure CLI](#tab/cli)
93
93
94
-
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.
94
+
1. Sign in to Azure CLI interactively with a browser even if you already signed in before.
95
95
96
96
```azurecli
97
97
az login
@@ -109,33 +109,24 @@ The Azure portal deployment experience is a helper tool that generates a deploym
109
109
110
110
Azure IoT Operations requires a schema registry on your cluster. Schema registry requires an Azure storage account so that it can synchronize schema information between cloud and edge.
111
111
112
-
Run the following CLI commands in your Codespaces terminal.
113
-
114
-
1. Set environment variables for the resources you create in this section.
115
-
116
-
| Placeholder | Value |
117
-
| ----------- | ----- |
118
-
| <STORAGE_ACCOUNT_NAME> | A name for your storage account. Storage account names must be between 3 and 24 characters in length and only contain numbers and lowercase letters. |
119
-
| <SCHEMA_REGISTRY_NAME> | A name for your schema registry. |
120
-
| <SCHEMA_REGISTRY_NAMESPACE> | A name for your schema registry namespace. The namespace uniquely identifies a schema registry within a tenant. |
112
+
1. Create a storage account with hierarchical namespace enabled.
1. Create a schema registry that connects to your storage account. This command also creates a blob container called **schemas** in the storage account if one doesn't exist already.
124
+
Use the optional parameters to customize your schema registry, including:
|`--custom-role-id`| Role definitio, ID | The schema registry needs read/write access to the storage account. Provide a custom role ID to use instead of the default **Storage Blob Data Contributor**. Format: `/subscriptions/<SUBSCRIPTION_ID>/providers/Microsoft.Authorization/roleDefinitions/<ROLE_ID>`. |
129
+
|`--sa-container`| string | Storage account container where schemas will be stored. If this container doesn't exist, it will be created. The default container name is **schemas**. |
139
130
140
131
### Deploy Azure IoT Operations
141
132
@@ -155,10 +146,10 @@ Run the following CLI commands in your Codespaces terminal.
155
146
1. Deploy Azure IoT Operations. This command takes several minutes to complete:
156
147
157
148
```azurecli
158
-
az iot ops create --cluster $CLUSTER_NAME --resource-group $RESOURCE_GROUP
149
+
az iot ops create --cluster <CLUSTER_NAME> --resource-group <RESOURCE_GROUP>
159
150
```
160
151
161
-
Use the [optional parameters](/cli/azure/iot/ops#az-iot-ops-init-optional-parameters) to customize your cluster, including:
152
+
Use the optional parameters to customize your instance, including:
162
153
163
154
| Optional parameter | Value | Description |
164
155
| --------- | ----- | ----------- |
@@ -190,9 +181,9 @@ Azure secret requires a user-assigned managed identity with access to the Azure
190
181
191
182
1. Create a user-assigned managed identity that has access to the Azure Key Vault.
While the deployment is in progress, you can watch the resources being applied to your cluster.
312
303
313
-
* If your terminal supports it, `init` displays the deployment progress.
304
+
If your terminal supports it, the `init` and `create` commands display the deployment progress.
314
305
315
306
:::image type="content" source="./media/howto-deploy-iot-operations/view-deployment-terminal.png" alt-text="A screenshot that shows the progress of an Azure IoT Operations deployment in a terminal.":::
316
307
317
308
Once the **Deploy IoT Operations** phase begins, the text in the terminal becomes a link to view the deployment progress in the Azure portal.
318
309
319
310
:::image type="content" source="./media/howto-deploy-iot-operations/view-deployment-portal.png" alt-text="A screenshot that shows the progress of an Azure IoT Operations deployment in the Azure portal." lightbox="./media/howto-deploy-iot-operations/view-deployment-portal.png":::
320
311
321
-
* Otherwise, or if you choose to disable the progress interface with `--no-progress` added to the `init` command, you can use kubectl commands to view the pods on your cluster:
312
+
Otherwise, or if you choose to disable the progress interface with `--no-progress` added to the commands, you can use kubectl commands to view the pods on your cluster:
Copy file name to clipboardExpand all lines: articles/iot-operations/deploy-iot-ops/howto-enable-secure-settings.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ The end-to-end sample articles skip the secure settings configuration and instea
22
22
23
23
* An Azure IoT Operations instance deployed with test settings, as in [Quickstart: Run Azure IoT Operations Preview in GitHub Codespaces](../get-started-end-to-end-sample/quickstart-deploy.md).
24
24
25
-
* Azure CLI installed on your development machine. For more information, see [How to install the Azure CLI](/cli/azure/install-azure-cli). This scenario requires Azure CLI version 2.53.0 or higher. Use `az --version` to check your version and `az upgrade` to update if necessary.
25
+
* Azure CLI installed on your development machine. This scenario requires Azure CLI version 2.64.0 or higher. Use `az --version` to check your version and `az upgrade` to update if necessary. For more information, see [How to install the Azure CLI](/cli/azure/install-azure-cli).
26
26
27
27
* The Azure IoT Operations extension for Azure CLI. Use the following command to add the extension or update it to the latest version:
Copy file name to clipboardExpand all lines: articles/iot-operations/deploy-iot-ops/howto-manage-update-uninstall.md
+21-4Lines changed: 21 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,6 +16,18 @@ ms.date: 09/23/2024
16
16
17
17
Use the Azure CLI and Azure portal to manage, uninstall, or update Azure IoT Operations instances.
18
18
19
+
## Prerequisites
20
+
21
+
* An Azure IoT Operations instance deployed to a cluster. For more information, see [Deploy Azure IoT Operations](./howto-deploy-iot-operations.md).
22
+
23
+
* Azure CLI installed on your development machine. This scenario requires Azure CLI version 2.64.0 or higher. Use `az --version` to check your version and `az upgrade` to update if necessary. For more information, see [How to install the Azure CLI](/cli/azure/install-azure-cli).
24
+
25
+
* The Azure IoT Operations extension for Azure CLI. Use the following command to add the extension or update it to the latest version:
26
+
27
+
```azurecli
28
+
az extension add --upgrade --name azure-iot-ops
29
+
```
30
+
19
31
## Manage
20
32
21
33
After deployment, you can use the Azure CLI and Azure portal to view and manage your Azure IoT Operations instance.
The Azure CLI and Azure portal offer different options for uninstalling Azure IoT Operations.
125
137
126
-
If you want to delete an entire Azure IoT Operations deployment, use the Azure CLI.
127
-
128
-
If you want to delete an Azure IoT Operations instance but keep the related resources in the deployment, use the Azure portal.
138
+
The Azure portal steps can delete an Azure IoT Operations instance, but can't affect the related resources in the deployment. If you want to delete the entire deployment, use the Azure CLI.
129
139
130
140
### [Azure CLI](#tab/cli)
131
141
132
142
Use the [az iot ops delete](/cli/azure/iot/ops#az-iot-ops-delete) command to delete the entire Azure IoT Operations deployment from a cluster. The `delete` command evaluates the Azure IoT Operations related resources on the cluster and presents a tree view of the resources to be deleted. The cluster should be online when you run this command.
133
143
144
+
The `delete` command streamlines the redeployment of Azure IoT Operations to the same cluster. It undoes the `create` command so that you can run `create`, `delete`, `create` again and so on without having to rerun `init`.
145
+
134
146
The `delete` command removes:
135
147
136
148
* The Azure IoT Operations instance
@@ -140,7 +152,12 @@ The `delete` command removes:
140
152
* Resources that you can configure in your Azure IoT Operations solution, like assets, MQTT broker, and dataflows.
141
153
142
154
```azurecli
143
-
az iot ops delete --cluster <CLUSTER_NAME> --resource-group <RESOURCE_GROUP>
155
+
az iot ops delete --name <INSTANCE_NAME> --resource-group <RESOURCE_GROUP>
156
+
```
157
+
158
+
To delete the instance and also remove the Azure IoT Operations dependencies (the output of `init`), add the flag `--include-deps`.
Copy file name to clipboardExpand all lines: articles/iot-operations/overview-iot-operations.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,7 +42,7 @@ There are two core elements in the Azure IoT Operations Preview architecture:
42
42
Azure IoT Operations runs on Arc-enabled Kubernetes clusters on the edge. You can deploy Azure IoT Operations by using the Azure portal or the Azure CLI.
43
43
44
44
> [!NOTE]
45
-
> During public preview, there's no support for upgrading an existing Azure IoT Operations deployment to a newer version. Instead, remove Azure IoT Operations from your cluster and then deploy the latest version. For more information, see [Update Azure IoT Operations](deploy-iot-ops/howto-deploy-iot-operations.md#update-azure-iot-operations).
45
+
> During public preview, there's no support for upgrading an existing Azure IoT Operations deployment to a newer version. Instead, remove Azure IoT Operations from your cluster and then deploy the latest version. For more information, see [Update Azure IoT Operations](./deploy-iot-ops/howto-manage-update-uninstall.md#update).
0 commit comments