Skip to content

Commit 78d1eb0

Browse files
committed
Update quickstart instructions for OPC PLC simulator configuration
1 parent 508ecd1 commit 78d1eb0

File tree

2 files changed

+34
-4
lines changed

2 files changed

+34
-4
lines changed

articles/iot-operations/get-started/quickstart-add-assets.md

Lines changed: 25 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ Complete [Quickstart: Deploy Azure IoT Operations Preview to an Arc-enabled Kube
2929

3030
To sign in to the Azure IoT Operations portal, you need a work or school account in the tenant where you deployed Azure IoT Operations. If you're currently using a Microsoft account (MSA), you need to create a Microsoft Entra ID with at least contributor permissions for the resource group that contains your **Kubernetes - Azure Arc** instance. To learn more, see [Known Issues > Create Entra account](../troubleshoot/known-issues.md#azure-iot-operations-preview-portal).
3131

32-
For this quickstart, we use the **OPC PLC simulator** as our OPC UA Server endpoint. Follow [How to configure an OPC PLC simulator to work with Azure IoT OPC UA Broker](../manage-devices-assets/howto-configure-opc-plc-simulator.md) to make sure that OPC PLC is properly installed and configured before you begin.
33-
3432
## What problem will we solve?
3533

3634
The data that OPC UA servers expose can have a complex structure and can be difficult to understand. Azure IoT Operations provides a way to model OPC UA assets as tags, events, and properties. This modeling makes it easier to understand the data and to use it in downstream processes such as the MQ broker and Azure IoT Data Processor Preview pipelines.
@@ -78,13 +76,36 @@ To add an asset endpoint:
7876
kubectl get assetendpointprofile -n azure-iot-operations
7977
```
8078

81-
After you define an asset, an OPC UA connector pod discovers it. The pod uses the asset endpoint that you specify in the asset definition to connect to an OPC UA server. You can use `kubectl` to view the discovery pod that was created when you added the asset endpoint. The pod name looks like `aio-opc-opc.tcp-1-8f96f76-kvdbt`:
79+
1. To enable the quickstart scenario, configure your asset endpoint to connect without mutual trust established. Run the following command:
80+
81+
```console
82+
kubectl patch AssetEndpointProfile opc-ua-connector-0 -n azure-iot-operations --type=merge -p '{"spec":{"additionalConfiguration":"{\"applicationName\":\"opc-ua-connector-0\",\"security\":{\"autoAcceptUntrustedServerCertificates\":true}}"}}'
83+
```
84+
85+
> [!CAUTION]
86+
> Don't use this configuration in production or pre-production environments. Exposing your cluster to the internet without proper authentication might lead to unauthorized access and even DDOS attacks.
87+
88+
1. To enable the configuration changes to take effect immediately, first find the name of your `aio-opc-supervisor` pod by using the following command:
8289

8390
```console
8491
kubectl get pods -n azure-iot-operations
8592
```
8693

87-
When the OPC PLC simulator is running, data flows from the simulator, to the connector, to the OPC UA broker, and finally to the MQ broker.
94+
The name of your pod looks like `aio-opc-supervisor-956fbb649-k9ppr`.
95+
96+
1. Restart the `aio-opc-supervisor` pod by using a command that looks like the following example. Use the `aio-opc-supervisor` pod name from the previous step:
97+
98+
```console
99+
kubectl delete pod aio-opc-supervisor-956fbb649-k9ppr -n azure-iot-operations
100+
```
101+
102+
After you define an asset, an OPC UA connector pod discovers it. The pod uses the asset endpoint that you specify in the asset definition to connect to an OPC UA server. You can use `kubectl` to view the discovery pod that was created when you added the asset endpoint. The pod name looks like `aio-opc-opc.tcp-1-8f96f76-kvdbt`:
103+
104+
```console
105+
kubectl get pods -n azure-iot-operations
106+
```
107+
108+
When the OPC PLC simulator is running, data flows from the simulator, to the connector, to the OPC UA broker, and finally to the MQ broker.
88109

89110
## Manage your assets
90111

articles/iot-operations/get-started/quickstart-deploy.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -285,6 +285,15 @@ az keyvault create --enable-rbac-authorization false --name "<your unique key va
285285
>[!TIP]
286286
>If you get an error that says *Your device is required to be managed to access your resource*, go back to the previous step and make sure that you signed in interactively.
287287
288+
1. These quickstarts use the **OPC PLC simulator** to generate sample data. To configure the simulator for the quickstart scenario, run the following command:
289+
290+
> [!IMPORTANT]
291+
> Don't use the following example in production, use it for simulation and test purposes only. The example lowers the security level for the OPC PLC so that it accepts connections from any client without an explicit peer certificate trust operation.
292+
293+
```azurecli
294+
az k8s-extension update --version 0.3.0-preview --name opc-ua-broker --release-train preview --cluster-name $CLUSTER_NAME --resource-group $RESOURCE_GROUP --cluster-type connectedClusters --auto-upgrade-minor-version false --config opcPlcSimulation.deploy=true --config opcPlcSimulation.autoAcceptUntrustedCertificates=true
295+
```
296+
288297
## View resources in your cluster
289298
290299
While the deployment is in progress, you can watch the resources being applied to your cluster. You can use kubectl commands to observe changes on the cluster or, since the cluster is Arc-enabled, you can use the Azure portal.

0 commit comments

Comments
 (0)