简体   繁体   中英

Azure - Web Deployment Task Failed [System.AggregateException - WebToolsException] ERROR_COULD_NOT_CONNECT_TO_REMOTESVC

Unable to deploy to Azure App Service. What might be possibly going wrong here?

Web 部署任务失败

10-10-2021 11:07:06 System.AggregateException: One or more errors occurred. ---> Microsoft.WebTools.Shared.Exceptions.WebToolsException: Build failed. Check the Output window for more details. --- End of inner exception stack trace --- ---> (Inner Exception #0) Microsoft.WebTools.Shared.Exceptions.WebToolsException: Build failed. Check the Output window for more details.<---

Microsoft.WebTools.Shared.Exceptions.WebToolsException: Build failed. Check the Output window for more details.

===================

I'm using Visual studio 2022 Preview.

I have Created and Published Web app Service in Azure , it Worked fine for me. please follow the below steps to resolve your issue.

  1. Go to the Azure Portal .
  2. Click on App Services.
  3. Click on your application service.
  4. Click on Configuration -->Application settings.
  5. Click Add new setting, and add the following entry: Name: WEBSITE_WEBDEPLOY_USE_SCM , Value: false

在此处输入图片说明

  1. Click on Save and close the Application settings window.

  2. Click on your application service.

  3. Download the publish profile by clicking on Get publish profile.

  4. Import the publish profile when publishing your application service to Azure from Visual Studio. 在此处输入图片说明

This disables SCM and enables you to publish your application service to Azure.

I tried this solution earlier, but this didn't work in my case, this was actually due to partially deleted publish profile under the properties folder. So completely clearing (leaving launchSettings.json intact) that and adding profile again helped me resolve this issue.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM