Skip to content

Commit 33c73a5

Browse files
authored
Add missing step , add permissions for user
1 parent f1a9780 commit 33c73a5

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

articles/key-vault/secrets/overview-storage-keys.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,17 @@ Use the Azure CLI [az role assignment create](/cli/azure/role/assignment?view=az
7373
```azurecli-interactive
7474
az role assignment create --role "Storage Account Key Operator Service Role" --assignee-object-id 93c27d83-f79b-4cb2-8dd4-4aa716542e74 --scope "/subscriptions/<subscriptionID>/resourceGroups/<StorageAccountResourceGroupName>/providers/Microsoft.Storage/storageAccounts/<YourStorageAccountName>"
7575
```
76+
### Give your user account permission to managed storage accounts
7677

78+
Use the Azure CLI [az keyvault-set-policy](/cli/azure/keyvault?view=azure-cli-latest#az-keyvault-set-policy) cmdlet to update the Key Vault access policy and grant storage account permissions to your user account.
79+
80+
```azurecli-interactive
81+
# Give your user principal access to all storage account permissions, on your Key Vault instance
82+
83+
az keyvault set-policy --name <YourKeyVaultName> --upn [email protected] --storage-permissions get list delete set update regeneratekey getsas listsas deletesas setsas recover backup restore purge
84+
```
85+
86+
Note that permissions for storage accounts aren't available on the storage account "Access policies" page in the Azure portal.
7787
### Create a Key Vault Managed storage account
7888

7989
Create a Key Vault managed storage account using the Azure CLI [az keyvault storage](/cli/azure/keyvault/storage?view=azure-cli-latest#az-keyvault-storage-add) command. Set a regeneration period of 90 days. After 90 days, Key Vault regenerates `key1` and swaps the active key from `key2` to `key1`. `key1` is then marked as the active key. Provide the command the following parameter values:

0 commit comments

Comments
 (0)