4
votes

I use the Deploy Azure App Service VSTS task to deploy an asp dotnet core API to an Azure API app using the Publish using Web Deploy option. The task runs without any errors but somehow I have to restart the API to get the new version.

Is that intended? Is there any flag that I can set to immediately get the deployment "live"? As a workaround I can add a restart task but I hope there is another way....

1
I can't reproduce this issue. I made a test with this projects docs.microsoft.com/en-us/azure/app-service-api/…, and remain the default value of the Azure App Service Deploy step/task. What's the result if you deploy API App with this project (ToDoListDataAPI)? - starian chen-MSFT
actually I am having similar issue - after I publish update to API, my client app seems to be using old API version, but when I run unit tests (they use new API version) - but for me restart did not help - Prokurors
I have the same issue. Wondering if someone knows how to fix it. Only restart works for me as well. - Taras Pelenio

1 Answers

4
votes

Are you using App Service Local Cache? https://docs.microsoft.com/en-us/azure/app-service/app-service-local-cache

If you are you will need to remove WEBSITE_LOCAL_CACHE_OPTION = Always property of your web app to have your publish show right away.

Otherwise you can always use a deployment slot to test your app before swapping in production.