Reputation: 7180
We had a Web Application working on an intranet and I'm trying to publish it to the internet using Visual Studio 2010. The destination server is running iis7 and the Web Management Service is running.
On Visual Studio 2010 my service URL is:
And site/application is:
Default Web Site/WebApp
Marking as IIS App on destination and Allow untrusted certificate is checked and i'm using an administration account.
Visual Studio return the following error:
Start Web Deploy Publish the Application/package to https://xxx.xxx.xxx.xxx:8172/MsDeploy.axd?site=Default%20Web%20Site ... C:\Program Files\MSBuild\Microsoft\VisualStudio\v10.0\Web\Microsoft.Web.Publishing.targets(3588,5): Error : Web deployment task failed.(Remote agent (URL https://xxx.xxx.xxx.xxx:8172/MsDeploy.axd?site=Default Web Site) could not be contacted. Make sure the remote agent service is installed and started on the target computer.)
Remote agent (URL https://xxx.xxx.xxx.xxx:8172/MsDeploy.axd?site=Default Web Site) could not be contacted. Make sure the remote agent service is installed and started on the target computer. An unsupported response was received. The response header 'MSDeploy.Response' was '' but 'v1' was expected. The remote server returned an error: (403) Forbidden.
Any ideas how to publish it without a valid SSL certificate?
Upvotes: 107
Views: 37293
Reputation: 956
In my case, after Enable remote connections checkbox, I need to reinstall Web Deploy to make it work.
Upvotes: 1
Reputation: 8666
Web Deploy can give you a whole bunch of errors if not setup correctly. Do yourself a favour and use the Web Platform Installer (https://www.microsoft.com/web/downloads/platform.aspx). You should uninstall WebDeploy first if you've already tried to install it. From the WebPI select: "Web Deploy 3.6 for Hosting Servers".
Upvotes: 9
Reputation: 21
I had the same problem. Talk about jumping through hoops... The solution requires set up of user and deployment permissions etc.
Diagnosis - A non-administrative user attempted to perform an operation with a Web Deploy provider for which the user is not currently authorized. Resolution - Web Deploy 2.0 setup, by default, creates Management Service Delegation Rules which allow non-administrators to perform operations with this provider. It is possible that a delegation rule required for this provider has not been setup correctly. Workaround: From the Programs Control Panel, run Repair on Web Deploy 2.0. Alternatively, create the delegation rule manually.
It turns out I had to create it manually from 'Configure the Web Deployment Handler'(see below for link), using this guide to 'Configure WMSVC and IIS Manager Permissions' and 'Create Delegation Rules for Web Deploy Users' sorted the problem.
notes: Diagnosed using 'web deploy error codes' from: http://www.iis.net/learn/publish/troubleshooting-web-deploy/web-deploy-error-codes and eventually configured using processes from 'Configure the Web Deployment Handler': http://www.iis.net/learn/publish/using-web-deploy/configure-the-web-deployment-handler
Upvotes: 2
Reputation: 3221
If you go into IIS,
Click on the server node in the "Connections" list,
Double click "Management Service" then you are taken to a screen which has an "Enable remote connections" check box.
This checkbox (and the rest of the sreen) maybe greyed out because the service is running. Just click the "Stop" link in the Actions pane, then check the "Enable remote connections" box and any other settings you want to change here, then click 'Apply' and 'Start' on the Actions pane again.
That should hopefully let you connect, with proper credentials, to the service from a remote machine. (If the correct ports and stuff are opened and all that jazz.)
I think this helps your situation. At least you won't get 403's but you may have some other MsDeploy error.
Upvotes: 268