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
In this article, you learn how to discover OPC UA data sources automatically. After you deploy Azure IoT Operations, you configure Azure IoT Akri Preview to discover OPC UA data sources at the edge. Azure IoT Akri creates custom resources in your Kubernetes cluster that represent the data sources it discovers. The ability to discover OPC UA data sources removes the need to [manually configure them by using the Azure IoT Operations (preview) portal](howto-manage-assets-remotely.md).
17
+
In this article, you learn how to discover OPC UA data sources automatically. After you deploy Azure IoT Operations Preview, you configure Azure IoT Akri Preview to discover OPC UA data sources at the edge. Azure IoT Akri creates custom resources in your Kubernetes cluster that represent the data sources it discovers. The ability to discover OPC UA data sources removes the need to [manually configure them by using the Azure IoT Operations (preview) portal](howto-manage-assets-remotely.md).
18
18
19
19
> [!IMPORTANT]
20
20
> Currently, you can't use Azure Device Registry to manage the assets that Azure IoT Akri discovers and creates.
@@ -23,7 +23,7 @@ Azure IoT Akri enables you to detect and create assets in the address space of a
23
23
24
24
## Prerequisites
25
25
26
-
- Install Azure IoT Operations Preview. To install Azure IoT Operations Preview for demonstration and exploration purposes, see [Quickstart: Deploy Azure IoT Operations Preview to an Arc-enabled Kubernetes cluster](../get-started/quickstart-deploy.md).
26
+
- Install Azure IoT Operations Preview. To install Azure IoT Operations for demonstration and exploration purposes, see [Quickstart: Deploy Azure IoT Operations Preview to an Arc-enabled Kubernetes cluster](../get-started/quickstart-deploy.md).
27
27
- Verify that the Azure IoT Akri pods are properly configured by running the following command:
Copy file name to clipboardExpand all lines: articles/iot-operations/manage-devices-assets/howto-configure-opc-plc-simulator.md
+27-22Lines changed: 27 additions & 22 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,28 +1,28 @@
1
1
---
2
2
title: Configure an OPC PLC simulator
3
-
description: How to configure an OPC PLC simulator to work with Azure IoT OPC UA Broker.
3
+
description: How to configure the OPC PLC simulator to work with Azure IoT OPC UA Broker. The simulator generates sample data for testing and development purposes.
4
4
author: dominicbetts
5
5
ms.author: dobett
6
6
ms.subservice: opcua-broker
7
7
ms.topic: how-to
8
-
ms.date: 03/01/2024
8
+
ms.date: 05/16/2024
9
9
10
10
# CustomerIntent: As a developer, I want to configure an OPC PLC simulator in my industrial edge environment to test the process of managing OPC UA assets connected to the simulator.
11
11
---
12
12
13
-
# Configure an OPC PLC simulator to work with Azure IoT OPC UA Broker Preview
13
+
# Configure the OPC PLC simulator to work with Azure IoT OPC UA Broker Preview
In this article, you learn how to configure and connect to an OPC UA server simulator with different nodes that generate random data, anomalies, and configuration of user defined nodes. For developers, an OPC UA simulator enables you to test the process of managing OPC UA assets that are connected to the simulator.
17
+
In this article, you learn how to configure and connect the OPC PLC simulator. The simulator simulates an OPC UA server with multiple nodes that generate random data and anomalies. You can configure user defined nodes. The OPC UA simulator lets you test the process of managing OPC UA assets with the [Azure IoT Operations (preview) portal](howto-manage-assets-remotely.md) or [Azure IoT Akri Preview](overview-akri.md).
18
18
19
19
## Prerequisites
20
20
21
-
Azure IoT Operations installed. For more information, see [Quickstart: Deploy Azure IoT Operations Preview to an Arc-enabled Kubernetes cluster](../get-started/quickstart-deploy.md). If you deploy Azure IoT Operations as described, the process installs an OPC PLC simulator.
21
+
A deployed instance of Azure IoT Operations Preview. To deploy Azure IoT Operations for demonstration and exploration purposes, see [Quickstart: Deploy Azure IoT Operations – to an Arc-enabled Kubernetes cluster](../get-started/quickstart-deploy.md). If you deploy Azure IoT Operations as described, the installation includes the OPC PLC simulator.
22
22
23
23
## Deploy the OPC PLC simulator
24
24
25
-
This section shows how to deploy the OPC PLC simulator.
25
+
This section shows how to deploy the OPC PLC simulator if you didn't include it when you first deployed Azure IoT Operations.
26
26
27
27
The following step lowers the security level for the OPC PLC so that it accepts connections from Azure Iot OPC UA Broker or any client without an explicit peer certificate trust operation.
The OPC PLC OPC UA server should run in the same deployment as a separate pod.
47
+
The OPC PLC simulator runs as a separate pod in the `azure-iot-operations` namespace. The pod name looks like `opcplc-000000-7b6447f99c-mqwdq`.
48
48
49
-
## Configure OPC UA mutual trust between Azure Iot OPC UA Broker Preview and the OPC PLC
49
+
## Configure mutual trust between Azure Iot OPC UA Broker and the OPC PLC
50
50
51
-
The application instance certificate of the OPC PLC is a self-signed certificate managed by cert-manager and stored in the `secret aio-opc-ua-opcplc-default-application-cert-000000` kubernetes secret.
51
+
To learn more about mutual trust in OPC UA, see [OPC UA certificates infrastructure for Azure IoT OPC UA Broker](overview-opcua-broker-certificates-management.md).
52
52
53
-
1. Get the certificate, run the following commands on your cluster, and push it to Azure Key Vault.
53
+
The application instance certificate of the OPC PLC simulator is a self-signed certificate managed by [cert-manager](https://cert-manager.io/) and stored in the `aio-opc-ua-opcplc-default-application-cert-000000` Kubernetes secret.
54
+
55
+
To configure mutual trust between Azure Iot OPC UA Broker and the OPC PLC simulator:
56
+
57
+
1. Get the certificate and push it to Azure Key Vault:
54
58
55
59
```bash
56
60
kubectl -n azure-iot-operations get secret aio-opc-ua-opcplc-default-application-cert-000000 -o jsonpath='{.data.tls\.crt}'| \
57
61
base64 -d | \
58
62
xargs -0 -I {} \
59
63
az keyvault secret set \
60
64
--name "opcplc-crt" \
61
-
--vault-name <azure-key-vault-name> \
65
+
--vault-name <your-azure-key-vault-name> \
62
66
--value {} \
63
67
--content-type application/x-pem-file
64
68
```
65
69
66
-
2. Configure the secret provider class (SPC) `aio-opc-ua-broker-trust-list` custom resource (CR) in the connected cluster. Use a K8s client such as kubectl to configure the secret `opcplc.crt`in the SPC object array in the connected cluster.
70
+
1. Add the certificate to the `aio-opc-ua-broker-trust-list` custom resource in the cluster. Use a Kubernetes client such as `kubectl` to configure the `opcplc.crt` secret in the `SecretProviderClass` object array in the cluster.
71
+
72
+
The following example shows a complete`SecretProviderClass` custom resource that contains the simulator certificate in a PEM encoded file with the .crt extension:
67
73
68
74
```yml
69
75
apiVersion: secrets-store.csi.x-k8s.io/v1
@@ -75,8 +81,8 @@ The application instance certificate of the OPC PLC is a self-signed certificate
75
81
provider: azure
76
82
parameters:
77
83
usePodIdentity: 'false'
78
-
keyvaultName: <azure-key-vault-name>
79
-
tenantId: <azure-tenant-id>
84
+
keyvaultName: <your-azure-key-vault-name>
85
+
tenantId: <your-azure-tenant-id>
80
86
objects: |
81
87
array:
82
88
- |
@@ -85,18 +91,19 @@ The application instance certificate of the OPC PLC is a self-signed certificate
85
91
objectAlias: opcplc.crt
86
92
```
87
93
88
-
The projection of the Azure Key Vault secrets and certificates into the cluster takes some time depending on the configured polling interval.
94
+
> [!NOTE]
95
+
> The time it takes to project Azure Key Vault certificates into the cluster depends on the configured polling interval.
89
96
90
-
Now, the Azure IoT OPC UA Broker the trust relationship with OPC PLC should be established and you can proceed to create an `AssetEndpointProfile` to connect to your OPC PLC simulation server.
97
+
The Azure IoT OPC UA Broker trust relationship with OPC PLC simulator is now established and you can create an `AssetEndpointProfile` to connect to your OPC PLC simulator.
91
98
92
99
## Optionally configure your `AssetEndpointProfile` without mutual trust established
93
100
94
-
You can optionally configure an asset endpoint profile for the OPC PLC to run without mutual trust established. If you understand the risks, you can turn off authentication for testing purposes.
101
+
Optionally, you can configure an asset endpoint profile without establishing mutual trust between OPC UA Broker and the OPC PLC simulator. If you understand the risks, you can turn off authentication for testing purposes.
95
102
96
103
> [!CAUTION]
97
-
> Don't configure for no authentication in production or pre-production. Exposing your cluster to the internet without authentication can lead to unauthorized access and even DDOS attacks.
104
+
> Don't configure for no authentication in production or pre-production environments. Exposing your cluster to the internet without authentication can lead to unauthorized access and even DDOS attacks.
98
105
99
-
To allow your asset endpoint profile to connect to any OPC PLC server without establishing mutual trust, use the `additionalConfiguration` setting to change the `AssetEndpointProfile` for OPC UA.
106
+
To allow your asset endpoint profile to connect to an OPC PLC server without establishing mutual trust, use the `additionalConfiguration` setting to modify the `AssetEndpointProfile` configuration.
100
107
101
108
Patch the asset endpoint with `autoAcceptUntrustedServerCertificates=true`:
Copy file name to clipboardExpand all lines: articles/iot-operations/manage-devices-assets/howto-configure-opcua-certificates-infrastructure.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
@@ -23,7 +23,7 @@ To learn more, see [OPC UA certificates infrastructure for Azure IoT OPC UA Brok
23
23
24
24
## Prerequisites
25
25
26
-
A deployed instance of Azure IoT Operations Preview. To deploy Azure IoT Operations Preview for demonstration and exploration purposes, see [Quickstart: Deploy Azure IoT Operations – to an Arc-enabled Kubernetes cluster](../get-started/quickstart-deploy.md).
26
+
A deployed instance of Azure IoT Operations Preview. To deploy Azure IoT Operations for demonstration and exploration purposes, see [Quickstart: Deploy Azure IoT Operations – to an Arc-enabled Kubernetes cluster](../get-started/quickstart-deploy.md).
27
27
28
28
## Configure a self-signed application instance certificate
0 commit comments