Skip to content

Commit 6e53680

Browse files
Merge pull request #287588 from dominicbetts/release-aio-m2-quickstarts
AIO: quickstart fixes
2 parents cb66f40 + ac9c9d5 commit 6e53680

File tree

2 files changed

+4
-10
lines changed

2 files changed

+4
-10
lines changed

articles/iot-operations/get-started-end-to-end-sample/quickstart-upload-telemetry-to-cloud.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,9 @@ az eventhubs eventhub create --name destinationeh --resource-group $RESOURCE_GRO
7070
# [PowerShell](#tab/powershell)
7171

7272
```powershell
73-
az eventhubs namespace create --name $CLUSTER_NAME.Substring(0, 24) --resource-group $RESOURCE_GROUP --disable-local-auth true
73+
az eventhubs namespace create --name $CLUSTER_NAME.Substring(0, [MATH]::Min($CLUSTER_NAME.Length, 24)) --resource-group $RESOURCE_GROUP --disable-local-auth true
7474
75-
az eventhubs eventhub create --name destinationeh --resource-group $RESOURCE_GROUP --namespace-name $CLUSTER_NAME.Substring(0, 24) --retention-time 1 --partition-count 1 --cleanup-policy Delete
75+
az eventhubs eventhub create --name destinationeh --resource-group $RESOURCE_GROUP --namespace-name $CLUSTER_NAME.Substring(0, [MATH]::Min($CLUSTER_NAME.Length, 24)) --retention-time 1 --partition-count 1 --cleanup-policy Delete
7676
```
7777

7878
---
@@ -92,7 +92,7 @@ az role assignment create --role "Azure Event Hubs Data Sender" --assignee $PRIN
9292
# [PowerShell](#tab/powershell)
9393

9494
```powershell
95-
$EVENTHUBRESOURCE = $(az eventhubs namespace show --resource-group $RESOURCE_GROUP --namespace-name $CLUSTER_NAME.Substring(0, 24) --query id -o tsv)
95+
$EVENTHUBRESOURCE = $(az eventhubs namespace show --resource-group $RESOURCE_GROUP --namespace-name $CLUSTER_NAME.Substring(0, [MATH]::Min($CLUSTER_NAME.Length, 24)) --query id -o tsv)
9696
9797
$PRINCIPAL = $(az k8s-extension list --resource-group $RESOURCE_GROUP --cluster-name $CLUSTER_NAME --cluster-type connectedClusters -o tsv --query "[?extensionType=='microsoft.iotoperations'].identity.principalId")
9898
@@ -126,7 +126,7 @@ kubectl apply -f dataflow.yaml
126126
```powershell
127127
Invoke-WebRequest -Uri https://raw.githubusercontent.com/Azure-Samples/explore-iot-operations/release-m2/samples/quickstarts/dataflow.yaml -OutFile dataflow.yaml
128128
129-
(Get-Content dataflow.yaml) | ForEach-Object { $_ -replace '<NAMESPACE>', $CLUSTER_NAME.Substring(0, 24) } | Set-Content dataflow.yaml
129+
(Get-Content dataflow.yaml) | ForEach-Object { $_ -replace '<NAMESPACE>', $CLUSTER_NAME.Substring(0, [MATH]::Min($CLUSTER_NAME.Length, 24)) } | Set-Content dataflow.yaml
130130
131131
kubectl apply -f dataflow.yaml
132132
```

articles/iot-operations/includes/deploy-mqttui.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,6 @@ ms.author: dobett
99

1010
Verify data is flowing to the MQTT broker by using the **mosquitto_sub** tool. In this example, you run the **mosquitto_sub** tool inside your Kubernetes cluster:
1111

12-
1. Run the following command to create a service account:
13-
14-
```console
15-
kubectl create serviceaccount mqtt-client -n azure-iot-operations
16-
```
17-
1812
1. Run the following command to deploy a pod that includes the **mosquitto_pub** and **mosquitto_sub** tools that are useful for interacting with the MQTT broker in the cluster:
1913

2014
<!-- TODO: Change branch to main before merging the release branch -->

0 commit comments

Comments
 (0)