Ever since I created a second subscription deployment with my service principle account has stopped working.
Here is an example of me trying to deploy a web app identified by the resource group and app name.
I have always used just a singular SP and then within each resource group made a role assignment with appropriate access.
I am currently deploying by hand from my local machine. Not ideal, but not a blocking issue.
Version: 1.0.2
Logs:
<span>az login --service-principal --username $AZURE_APP_ID --password $AZURE_PASSWORD --tenant $AZURE_TENANT_ID</span><span><br>[</span><span> {</span><span> "cloudName": "AzureCloud",</span><span> "id": "864bf978-b99e-47fb-b50e-df6aa28f7674",</span><span> "isDefault": true,</span><span> "name": "Windows Azure MSDN ? Visual Studio Ultimate",</span><span> "state": "Enabled",</span><span> "tenantId": "$AZURE_TENANT_ID",</span><span> "user": {</span><span> "name": "$AZURE_APP_ID",</span><span> "type": "servicePrincipal"</span><span> }</span><span> },</span><span> {</span><span> "cloudName": "AzureCloud",</span><span> "id": "6ea67b78-9320-4c04-9872-cc04f4749ec4",</span><span> "isDefault": false,</span><span> "name": "Client-Lundbeck",</span><span> "state": "Enabled",</span><span> "tenantId": "$AZURE_TENANT_ID",</span><span> "user": {</span><span> "name": "$AZURE_APP_ID",</span><span> "type": "servicePrincipal"</span><span> }</span><span> }</span><span>]</span><span><br>INFO: Starting deployment to Azure app service...</span><span>az webapp deployment source config-zip --resource-group K37952-CliniHub-test --name k37952-clinihub-test-main-wa --src <a href="http://app.zip" target="_blank" rel="noopener nofollow noreferrer">app.zip</a></span><span><br><strong>ERROR: ResourceGroupNotFound - Resource group 'K37952-CliniHub-test' could not be found.</strong></span>ERROR: ResourceGroupNotFound - Resource group 'K37952-CliniHub-test' could not be found.<span>INFO: Signing in...</span>
Steps to reproduce. (I have done these twice with the same error)
- Have one subscription.
- Create a SP.
- Create a RG and a webapp.
- Make a role assignment to the RG with the SP
- Run the pipelines (works)
- Create a second subscription.
- Create a new RG and a webapp
- Make a role-assignment to the new RG with the SP
- Run the pipelines with updated variables to target the new RG. (fails)