6

I want to deploy my project to Azure in an App Service I have just created. Also, I created a KeyVault for all my settings.

When I try to deploy to app to the service, I have to configure the connection strings for the databases.

enter image description here

I click on Configure and follow the instruction and select the right app service or KeyVault. Then, in the last step, I receive this error.

Dependency configuration progress

Failed to resolve token 'ProfileResourceId'.

ErrorEmpty parameter 'resourceId'...

ErrorFailed to configure Azure AppService settings.

Failed to configure dependency Azure Key Vault secrets1

enter image description here

How can I fix it?

More details

I didn't follow any documentation. Usually, I use Azure DevOps to deploy application to Azure. In this case, I prefer to deploy the application from my laptop.

For that, I downloaded the publish profile from the portal and added in Visual Studio.

enter image description here

Then, I see some alert. At the beginning I ignored the alert but the deployed application doesn't work. So, I tried to configure each dependence.

enter image description here

If I press on the + to add a new service dependency, I select Azure Key Vault. Select the Azure subscription and the keyvault. Then, the local variable and review the setting. Then Finish.

enter image description here

enter image description here

enter image description here

30719-image.png

In the solution I see some files for ServiceDependencies

enter image description here

What it is strange to me is that in the project I successful configured the Connected Services.

enter image description here

Enrico
  • 3,592
  • 6
  • 45
  • 102
  • There is a link in the first screen capture to configure azure KeyVault, did you try that out already? Are you logged in your visual studio instance with the same user than the one you are logged on in Azure Portal? Do you have more details on how you reached this state (minimum reproducible example) ? – Irwene Oct 07 '20 at 15:36
  • I added some updates. Also, I opened a ticket on Microsoft and PSC https://www.puresourcecode.com/forum/topic/visual-studio-2019-azure-keyvault-configuration-error-when-publish/#postid-57 – Enrico Oct 08 '20 at 09:07

1 Answers1

1

I had a similar issue with Application Insights. I was able to resolve by clicking "Restore service dependencies and their settings" in the Publish window.

After clicking, I was able to configure my dependencies without the "Failed to resolve token 'ProfileResourceId'." error.

Service Dependencies Configuration Window

blackgreen
  • 34,072
  • 23
  • 111
  • 129