azure-pipelines-tasks: [BUG]: 404 Failed to deploy web package to App Service (Linux)
Task name
AzureRmWebAppDeployment
Task version
4
Environment type (Please select at least one enviroment where you face this issue)
- Self-Hosted
- Microsoft Hosted
- VMSS Pool
- Container
Azure DevOps Server type
dev.azure.com (formerly visualstudio.com)
Azure DevOps Server Version (if applicable)
No response
Operation system
Windows
Task log
##[debug][POST]https://$contoso-project-int-ase-front:***@contoso-project-int-ase-front.scm.azurewebsites.net/api/zipdeploy?isAsync=true&deployer=VSTS_ZIP_DEPLOY&message=%7B%22type%22%3A%22deployment%22%2C%22commitId%22%3A%22ca18ed0cf5370f2079a1256627325eb63b909842%22%2C%22buildId%22%3A%226477%22%2C%22buildNumber%22%3A%22Extranet_release-v1.1.7_2023.08.01.3%22%2C%22repoProvider%22%3A%22TfsGit%22%2C%22repoName%22%3A%22contoso-Extranet%22%2C%22collectionUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F%22%2C%22teamProject%22%3A%220d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22buildProjectUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F0d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22repositoryUrl%22%3A%22https%3A%2F%2Fcompany-unit%40dev.azure.com%2Fcompany-unit%2Fcontoso-Extranet%2F_git%2Fcontoso-Extranet%22%2C%22branch%22%3A%22release-v1.1.7%22%2C%22teamProjectName%22%3A%22contoso-Extranet%22%2C%22slotName%22%3A%22production%22%7D
##[debug]ZIP Deploy response: {"statusCode":202,"statusMessage":"Accepted","headers":{"content-length":"0","connection":"close","date":"Tue, 01 Aug 2023 08:08:46 GMT","server":"Kestrel","location":"https://contoso-project-int-ase-front.scm.azurewebsites.net:443/api/zipdeploy?isAsync=true&deployer=VSTS_ZIP_DEPLOY&message=%7B%22type%22%3A%22deployment%22%2C%22commitId%22%3A%22ca18ed0cf5370f2079a1256627325eb63b909842%22%2C%22buildId%22%3A%226477%22%2C%22buildNumber%22%3A%22Extranet_release-v1.1.7_2023.08.01.3%22%2C%22repoProvider%22%3A%22TfsGit%22%2C%22repoName%22%3A%22contoso-Extranet%22%2C%22collectionUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F%22%2C%22teamProject%22%3A%220d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22buildProjectUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F0d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22repositoryUrl%22%3A%22https%3A%2F%2Fcompany-unit%40dev.azure.com%2Fcompany-unit%2Fcontoso-Extranet%2F_git%2Fcontoso-Extranet%22%2C%22branch%22%3A%22release-v1.1.7%22%2C%22teamProjectName%22%3A%22contoso-Extranet%22%2C%22slotName%22%3A%22production%22%7D/api/deployments/latest?deployer=VSTS_ZIP_DEPLOY&time=2023-08-01_08-08-46Z","scm-deployment-id":"a075012a-fa1d-4691-9f2e-c7f5555b1eba","retryafter":"30"}}
##[debug]Polling for ZIP Deploy URL: https://contoso-project-int-ase-front.scm.azurewebsites.net:443/api/zipdeploy?isAsync=true&deployer=VSTS_ZIP_DEPLOY&message=%7B%22type%22%3A%22deployment%22%2C%22commitId%22%3A%22ca18ed0cf5370f2079a1256627325eb63b909842%22%2C%22buildId%22%3A%226477%22%2C%22buildNumber%22%3A%22Extranet_release-v1.1.7_2023.08.01.3%22%2C%22repoProvider%22%3A%22TfsGit%22%2C%22repoName%22%3A%22contoso-Extranet%22%2C%22collectionUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F%22%2C%22teamProject%22%3A%220d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22buildProjectUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F0d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22repositoryUrl%22%3A%22https%3A%2F%2Fcompany-unit%40dev.azure.com%2Fcompany-unit%2Fcontoso-Extranet%2F_git%2Fcontoso-Extranet%22%2C%22branch%22%3A%22release-v1.1.7%22%2C%22teamProjectName%22%3A%22contoso-Extranet%22%2C%22slotName%22%3A%22production%22%7D/api/deployments/latest?deployer=VSTS_ZIP_DEPLOY&time=2023-08-01_08-08-46Z
##[debug]setting affinity cookie
##[debug]CLIENT_RESETSTREAMONRETRY=undefined
##[debug][GET]https://contoso-project-int-ase-front.scm.azurewebsites.net:443/api/zipdeploy?isAsync=true&deployer=VSTS_ZIP_DEPLOY&message=%7B%22type%22%3A%22deployment%22%2C%22commitId%22%3A%22ca18ed0cf5370f2079a1256627325eb63b909842%22%2C%22buildId%22%3A%226477%22%2C%22buildNumber%22%3A%22Extranet_release-v1.1.7_2023.08.01.3%22%2C%22repoProvider%22%3A%22TfsGit%22%2C%22repoName%22%3A%22contoso-Extranet%22%2C%22collectionUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F%22%2C%22teamProject%22%3A%220d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22buildProjectUrl%22%3A%22https%3A%2F%2Fdev.azure.com%2Fcompany-unit%2F0d311dd0-de9f-4189-b738-60f14ef6869d%22%2C%22repositoryUrl%22%3A%22https%3A%2F%2Fcompany-unit%40dev.azure.com%2Fcompany-unit%2Fcontoso-Extranet%2F_git%2Fcontoso-Extranet%22%2C%22branch%22%3A%22release-v1.1.7%22%2C%22teamProjectName%22%3A%22contoso-Extranet%22%2C%22slotName%22%3A%22production%22%7D/api/deployments/latest?deployer=VSTS_ZIP_DEPLOY&time=2023-08-01_08-08-46Z
##[debug]Could not parse response: {}
##[debug]Response: undefined
##[error]Failed to deploy web package to App Service.
##[debug]Processed: ##vso[task.issue type=error;]Failed to deploy web package to App Service.
##[debug]Deployment Failed with Error: Error: Error: Failed to deploy web package to App Service. Not Found (CODE: 404)
##[debug]task result: Failed
##[error]Error: Error: Failed to deploy web package to App Service. Not Found (CODE: 404)
....
##[debug][PUT]https://$contoso-project-int-ase-front:***@contoso-project-int-ase-front.scm.azurewebsites.net/api/deployments/64771690877327941
##[debug]Could not parse response: {}
##[debug]Response: undefined
##[debug]updateDeployment. Data: {"statusCode":409,"statusMessage":"Conflict","headers":{"connection":"close","content-type":"text/plain; charset=utf-8","date":"Tue, 01 Aug 2023 08:08:47 GMT","server":"Kestrel","transfer-encoding":"chunked"},"body":"The 'Performing deployment' operation conflicts with the pending 'Deployment' operation started at 08/01/2023 08:08:46. Please retry operation later."}
##[warning]Error: Failed to update deployment history. Error: Conflict (CODE: 409)
Relevant log output
##[error]Failed to deploy web package to App Service.
##[error]Error: Error: Failed to deploy web package to App Service. Not Found (CODE: 404)
...
##[warning]Error: Failed to update deployment history. Error: Conflict (CODE: 409)
Aditional info
The deployment actually works and is visible in the deployment log.
However the task fails with this 404 error. It looks like the polling for deployment status is failing
This error appeared suddenly across environments. (Across different App plan instances/SKU)
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 6
- Comments: 26 (3 by maintainers)
Same issue:
One thing I have noticed is- If I change any setting in my webapp while its being deployed it usually gives that error. And it gets deployed correctly If I just do a simple redeploy ( In my case add a little space somewhere in code and git push again )
Hello @jammyzt,
Just did a test run and it seems to be working correctly for an app that was consistently failing until then. I’m leaving the issue open in case this has not been fixed for everyone.
Deploy WebApp to Azure 1 Run azure/webapps-deploy@v2 11 Package deployment using ZIP Deploy initiated. 12 Error: Failed to deploy web package to App Service 13 Error: Deployment Failed, Erro: Failed to deploy web package to App Service. 14 Not Found (CODE: 404) 15 App Service Application URL: http://<removed>
problems started from 2023.08.01 it was all fine for 2 years.
We had the exact same issue. He deleted the app service and recreated a new one and it fixed the issue.
same error for me too
Same thing here - except we’re using AzureWebApp - same errors though, so wonder if there is something underlying supporting these
Hello @leivavictor and @vivelys.
The task is still usable (kind of) , as this is only the polling for deployment status that fails, deployment is actually launched. So if you don’t have any task that depends directly on the deployment in your pipeline you can simply set the task to continue on error for now.
By the way, this problem did not appear in another similar project.
Hi Eazyed and leivavictor, I’m facing the same problem. The deployment appears to have failed, but when I look in my web app log, the correct version is deployed. However, as the deployment appears to have failed, my pipeline stops.