Visual Studio 2010 Web deployment task failed

前端 未结 15 1500
花落未央
花落未央 2020-12-01 01:31

I am trying to use VS2010\'s 1-Click Publish feature to deploy a test site from my laptop to my server. I have the firewall turned off on both machines and the MS Deployment

相关标签:
15条回答
  • 2020-12-01 02:11

    We found the issue was because WebDeploy was installed before the Web Management Service feature was enabled on a Windows 2008 server. After Web Management Service is installed, uninstall Web Deploy fully. Then resinstall and make sure all components of the package are selected.

    Following the reinstallation we were immediately able to publishing to the server from my local machine, and also from our CI.

    A couple of points to note after reading the other answers:

    • If you are getting a 404 error the problem is not one of security.
    • We did not have to restart Visual Studio for this change to take effect.
    • Reinstallation will kick off the services in automatic mode, do not adust this setting.
    0 讨论(0)
  • 2020-12-01 02:11

    This same message would occur almost at random when publishing projects from visual studio 2010.

    The fix was to delete the $projectname.Publish.xml file (in the root directory of the project) and re-create it.

    0 讨论(0)
  • 2020-12-01 02:12

    If you are using an SSL certificate you should go into Management Service under the IIS Manager section of Server Manager and stop the service, select the correct certificate and then start the service again. This is what worked for me (I was getting Forbidden message).

    0 讨论(0)
  • 2020-12-01 02:14

    Even though all required software are installed I had similar error. I noticed that the service URL didn't prefixed with http://. Once prefixed it works well.

    0 讨论(0)
  • 2020-12-01 02:16

    Make sure you have the WMSvc Service (Web Management Service) set to 'Auto' (and started) so it's on when you restart & check out this link

    0 讨论(0)
  • 2020-12-01 02:16

    Although a lot of different unrelated things can contribute to getting the 404, I solved it for my by.

    1. When installing/reinstalling the WebDeploy installer, choose Custom/Change and then ensure that 'Management Service Delegation UI' is one of the installed options, it is not installed by default, but is required for WebDeploy to work (installer bug).
    2. Use the new Management Service Delegation icon in the Server node of the IIS manager to add the 'Deploy Applications with Content' role, accepting it's default settings. But you may also want to specify a "Run As" setting with a user that has rights to modify IIS settings.
    3. Restart the Web Management Service.

    After this, everything works fine. Assuming the Web Management Service is setup correctly (mine is configured to accept remote connections, the firewall port was opened, and the user I'm uploading with was added to every single Site that I want to deploy to (using the IIS Manager Permissions icon in each Site node in the IIS Manager)).

    0 讨论(0)
提交回复
热议问题