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
Error
az role assignment create --role "Key Vault Secrets Officer"
--scope $KEYVAULT_ID
--assignee-object-id $USER_ID
This command or command group has been migrated to Microsoft Graph API. Please carefully review all breaking changes introduced during this migration: https://docs.microsoft.com/cli/azure/microsoft-graph-migration
argument --assignee-object-id: expected one argument
Error on AzureCLI task using Pipeline
The text was updated successfully, but these errors were encountered:
For example, the most outstanding change is that the objectId property in the output JSON of a Graph object is replaced by id.
Maybe the following will work?
# assign RBAC role to the current user to manage secrets
#USER_ID=$(az ad signed-in-user show --query objectId -o tsv)
USER_ID=$(az ad signed-in-user show --query id -o tsv)
and..
#SPN_ID=$(az ad sp list --display-name "spn-keyvault-devops" --query [0].objectId --out tsv)
SPN_ID=$(az ad sp list --display-name "spn-keyvault-devops" --query [0].id --out tsv)
Hi!
Not to disappoint you, but I have done a checkout, applied above patched, and did a re-run.
Downloading secrets using: https://keyvault021.vault.azure.net/secrets?maxresults=25&api-version=2016-10-01.
##[error]Get secrets failed. Error: Caller is not authorized to perform action on resource.
(Even with automatic SP and manual SP configuration in azure devops)
So this issue is not resolved for you yet... I suppose...
Did not investigate what could be the problem then
Error
az role assignment create --role "Key Vault Secrets Officer"
--scope $KEYVAULT_ID
--assignee-object-id $USER_ID
This command or command group has been migrated to Microsoft Graph API. Please carefully review all breaking changes introduced during this migration: https://docs.microsoft.com/cli/azure/microsoft-graph-migration
argument --assignee-object-id: expected one argument
Error on AzureCLI task using Pipeline
The text was updated successfully, but these errors were encountered: