0
votes

As we are deploying to the already existing applications our files get locked.

How should we add the appofline file so the deployments can use that file and coordinate with VSTS pipeline ?

VSTS Pipeline

enter image description here

ERROR MESSAGE

2017-10-03T15:07:34.9492376Z Info: Updating file (xxx-xxxx-dev\xxx.xxx.Web.dll). 2017-10-03T15:07:37.8157267Z ##[error]Failed to deploy web package to App Service. 2017-10-03T15:07:37.8187261Z ##[warning]Try to deploy app service again with Rename locked files option selected. 2017-10-03T15:07:37.8187261Z ##[error]Error Code: ERROR_FILE_IN_USE More Information: Web Deploy cannot modify the file 'xxx.xxxx.Web.dll' on the destination because it is locked by an external process. In order to allow the publish operation to succeed, you may need to either restart your application to release the lock, or use the AppOffline rule handler for .Net applications on your next publish attempt. Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_FILE_IN_USE. Error count: 1.

1
Do you solve this issue?starian chen-MSFT

1 Answers

1
votes

The Task App Offline option of Azure App Service Deploy task will take the app service offline, since it doesn’t work for you, you can stop or restart azure web app through Stop-AzureRMWebApp/Restart-AzureRmWebApp powershell through Azure PowerShell task or use "Azure App Service Manage" task and then deploy package through Azure App Service Deploy task.