Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Note
The best way to start debugging errors related to Azure Web App tasks is to gather debug logs for pipelines and collect the logs by using Kudu service and the Diagnose and solve problems feature.
Errors and resolutions
Error 1: "FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory"
Resolution:
This error may occur due to a failure to unzip and zip a large package for the deployment, as Microsoft-hosted agents have limited resources. In the logs, you see the steps where it's failing. Preferably, use the Azure Web App V1 task for App Services deployment. For more complicated scenarios like XML transformation, see Azure RM Web Deployment V4 task.
Error 2: "Encountered a retriable error:ECONNRESET. Message: read ECONNRESET"
Resolution:
If you're using the Microsoft-hosted agent and App Services in an ASE environment, make sure you have opened the IP addresses for the Microsoft-hosted agent geography. See Allowed IP addresses and domain URLs for IP address ranges of incoming connections.
If you're using a self-hosted agent, apart from unblocking the IP range for the self-hosted agent, the problem could be due to a flaky network issue. Consider creating a support ticket with the Azure Web App or Azure Networking team for troubleshooting in this area.
Error 3: "Failed to deploy web package to App Service"
The task calls a zipDeploy Kudu API for deployment. The following error generally comes in response to some operations performed by the API.
[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: Package deployment using ZIP Deploy failed.
Refer logs for more details.
[debug]task result: Failed
Resolution:
Try setting the WEBSITE_RUN_FROM_PACKAGE app setting to 1 on the App Services side.
Error 4: "EMFILE: too many open files" or "Error: Package deployment using ZIP Deploy failed"
Possible workarounds:
Use the Azure Web App V1 task.
Use the following Extract Files task to extract the zip file into a folder path, and then provide the folder path into the App Service Deploy task. This step prevents the App Service task from unzipping the package, preventing EMFILE errors.
steps: - task: ExtractFiles@1 displayName: 'Extract files' inputs: archiveFilePatterns: '$(InputPackageZipPath)' destinationFolder: '$(OutputUnzippedPath)' - task: AzureRmWebAppDeployment@4 displayName: 'Azure App Service Deploy' inputs: azureSubscription: 'Subscription' WebAppName: 'app-name' package: '$(OutputUnzippedPath)' enableXmlTransform: true