I’am on Octopus 3.3.11
Enable AppOffline during deployment to Azure Web App sometime seems to not work.
"Microsoft.Web.Deployment.DeploymentDetailedClientServerException: Web Deploy cannot modify the file ‘’ 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."
I think the problem in AppOffline feature. In description said that it add app_offline.html to the site root folder.
But to make Azure Web App offline file need to be named as app_offline.htm
So, from my point of view feature adding file working wrong due to incorrect file extension.
If I’m not wrong, please fix it.
Thanks for reaching out. Would you mind following the below instructions and send us a deployment log so we can see the full context of the error?
1) Add these 2 variables to your project http://docs.octopusdeploy.com/display/OD/Debug+problems+with+Octopus+variables
2) Create a new release (so the new variables take effect) and deploy it. If possible skip as many steps as you can and only leave step we are troubleshooting in order to avoid the noise in the log.
3) Send us the raw log of that deployment http://docs.octopusdeploy.com/display/OD/Get+the+raw+output+from+a+task
This issue has been closed due to inactivity. If you encounter the same or a similar issue and require help, please open a new discussion (if we asked for logs or extra details in this thread, consider including them in the new thread). If you are the creator of this thread and believe it should not be closed let us know via our support email.