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
Before you can create a container to upload the blob to, you'll need to assign the [Storage Blob Data Contributor](../../role-based-access-control/built-in-roles.md#storage-blob-data-contributor) role to yourself. For this example, the role will be assigned to the storage account you've made earlier.
42
42
43
43
```azurecli
44
-
az role assignment create --role "Storage Blob Data Contributor" --assignee [email protected] --scope "/subscriptions/aaaaaaaa-bbbb-bbbb-cccc-dddddddddddd/resourceGroups/contosoResourceGroup5/providers/Microsoft.Storage/storageAccounts/contosoblobstorage5
44
+
az role assignment create --role "Storage Blob Data Contributor" --assignee [email protected] --scope "/subscriptions/{subscription-id}/resourceGroups/contosoResourceGroup5/providers/Microsoft.Storage/storageAccounts/contosoblobstorage5
45
45
```
46
46
47
47
Now that you've assign the role to storage account, you can create a container for your blob.
Copy file name to clipboardExpand all lines: articles/key-vault/general/manage-with-cli2.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -205,16 +205,16 @@ az ad sp create-for-rbac -n "MyApp" --password "hVFkk965BuUv" --role Contributor
205
205
206
206
To authorize the application to access the key or secret in the vault, use the `az keyvault set-policy` command.
207
207
208
-
For example, if your vault name is ContosoKeyVault, the application has an appID of 8f8c4bbd-485b-45fd-98f7-ec6300b7b4ed, and you want to authorize the application to decrypt and sign with keys in your vault, use the following command:
208
+
For example, if your vault name is ContosoKeyVaultand you want to authorize the application to decrypt and sign with keys in your vault, use the following command with your application ID:
209
209
210
210
```azurecli
211
-
az keyvault set-policy --name "ContosoKeyVault" --spn 8f8c4bbd-485b-45fd-98f7-ec6300b7b4ed --key-permissions decrypt sign
211
+
az keyvault set-policy --name "ContosoKeyVault" --spn {application-id} --key-permissions decrypt sign
212
212
```
213
213
214
214
To authorize the same application to read secrets in your vault, type the following command:
215
215
216
216
```azurecli
217
-
az keyvault set-policy --name "ContosoKeyVault" --spn 8f8c4bbd-485b-45fd-98f7-ec6300b7b4ed --secret-permissions get
217
+
az keyvault set-policy --name "ContosoKeyVault" --spn {application-id} --secret-permissions get
0 commit comments