Skip to content

Commit 6e86a23

Browse files
authored
Update cosmos-db-managed-identity.md
added CLI interactive to powershell command
1 parent 0283d2a commit 6e86a23

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

articles/stream-analytics/cosmos-db-managed-identity.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: enkrumah
55
ms.author: ebnkruma
66
ms.service: stream-analytics
77
ms.topic: how-to
8-
ms.date: 08/25/2022
8+
ms.date: 08/30/2022
99
ms.custom: subject-rbac-steps
1010
---
1111

@@ -48,9 +48,10 @@ For the Stream Analytics job to access your Cosmos DB using managed identity, th
4848
4949
The following command can be used to authenticate your ASA job with CosmosDB. The `$accountName` and `$resourceGroupName` are for your CosmosDB account, and the `$principalId` is the value obtained in the previous step, in the Identity tab of your ASA job. You need to have "Contributor" access to your CosmosDB account for this command to work as intended.
5050

51-
51+
```azurecli-interactive
5252
New-AzCosmosDBSqlRoleAssignment -AccountName $accountName -ResourceGroupName $resourceGroupName -RoleDefinitionId '00000000-0000-0000-0000-000000000002' -Scope "/" -PrincipalId $principalId
5353
54+
```
5455

5556
> [!NOTE]
5657
> Due to global replication or caching latency, there may be a delay when permissions are revoked or granted. Changes should be reflected within 8 minutes.

0 commit comments

Comments
 (0)