Hi all,
I'm trying to assign a RBAC in Azure pipeline, I'm using below task in the yaml file
task: AzureCLI@2
inputs:
azureSubscription: 'AzureRmPipeline-conn'
scriptType: 'bash'
scriptLocation: 'inlineScript'
inlineScript: 'az role assignment create --role "Storage Blob Data Contributor" --assignee <some email> --scope "<some scope>'
addSpnToEnvironment: true
AzureRmPipeline-conn is service connection to the subscription and I can use it deploy resource to the resource group already.
However when I run the pipeline I got below error
ERROR: Insufficient privileges to complete the operation.
[error]Script failed with exit code: 1
Does anyone know how to resolve that? Many thanks!
Regards,
Alex