Skip to content

Commit e447038

Browse files
Merge pull request #311847 from apurbasroy/patch-14
Add troubleshooting for ARM template configuration issue
2 parents 249b15d + 93c5501 commit e447038

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

articles/hdinsight/hdinsight-with-entra-authentication/manage-entra-id-enabled-azure-hdinsight-clusters-with-arm-templates.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -264,6 +264,27 @@ To create a Microsoft.HDInsight/clusters resource, add the following JSON to you
264264
}
265265
}
266266
```
267+
## Troubleshooting
268+
269+
### Issue
270+
The problem occurs with the restAuthEntraUsers value in the gateway configuration. Azure Resource Manager (ARM) treats any string that starts with [ as an ARM expression. As a result, when ARM encounters the JSON array value, it attempts to interpret it as an ARM function, which causes the deployment to fail.
271+
272+
### Resolution
273+
To prevent ARM from interpreting the value as an expression, escape the opening bracket by using [[ instead of [. This forces ARM to treat the value as a literal string and pass it through correctly to HDInsight.
274+
275+
### Example
276+
Before (deployment fails):
277+
```json
278+
"restAuthEntraUsers": "[{\"displayName\":\"John Doe\",\"objectId\":\"<Object ID>\",\"upn\":\"[email protected]\"},{\"displayName\":\"Jane Doe\",\"objectId\":\"<Object ID>\",\"upn\":\"[email protected]\"},{\"displayName\":\"abc\",\"objectId\":\"<Object ID>\",\"upn\":\"[email protected]\"}]"
279+
```
280+
281+
After (deployment succeeds):
282+
283+
```json
284+
"restAuthEntraUsers": "[[{\"displayName\":\"John Doe\",\"objectId\":\"<Object ID>\",\"upn\":\"[email protected]\"},{\"displayName\":\"Jane Doe\",\"objectId\":\"<Object ID>\",\"upn\":\"[email protected]\"},{\"displayName\":\"abc\",\"objectId\":\"<Object ID>\",\"upn\":\"[email protected]\"}]"
285+
```
286+
> [!NOTE]
287+
> The only required change is the additional "[" at the beginning of the value.
267288
268289
## Property Values
269290

0 commit comments

Comments
 (0)