Iis – Can’t connect to MSDeploy service from Visual Studio 2013

deploymentiisiis-8

The Situation

I have a hosted server that has our development webserver on it. I have installed the Web Management Service (via Web Platform Installer) and have setup an IIS Management user, setup delegations, started the service and I am trying to connect to the service via the Visual Studio 2013 Publish Web dialog with the Validate Connection button.

I am using an address like the following:
https://169.254.0.0:8172/msdeploy.axd (obviously the IP address has been changed, but I am absolutely sure the one i am using is correct as that is what I am connecting to for RDP. I have also tried http as per this SF article: How to configure WebDeploy server for direct publishing from visual studio?

I have ensured that the services (Web Management and Web Deploy Agent) are running, and that the firewall is not blocking communication ( I have tried turning it off).

Previously I have had luck with this for servers that were on the LAN and on the domain, but this one is neither. Any suggestions would be appreciated.

Update

Windows Firewall was not administering port restrictions

The servers port restrictions were being managed by Azure (I did not know this going into this project). Got the 8172 TCP port opened, and used the http version of the address above. Now error is: Could not complete the request to remote agent URL 'http://.../msdeploy.axd/MSDEPLOYAGENTSERVICE'. The operation has timed out.

404.7 Error in the Error Logs

Along with the above timeout error message, I looked in the logs again and noticed that the HTTP error coming back is a 404.7 : Not Found The request filtering module is configured to deny the file extension. I looked in Handler Mappings and there are handlers for *.axd and they appear to be enabled and allowable. This is making me angry.

Best Answer

This was a combination of problems:

  1. Windows Firewall was not blocking port 8172 TCP, Azure was. The moral: interrogate higher ups as to the true nature of the server beast you are getting ready to modify.
  2. MsDeployServiceURL should be https in this case. The moral: sometimes statements that sound like they are cut and dried 'This is the way it is' are not to be trusted.
  3. Had to install an additional module or feature for Web Deploy: Unable to use "Web deploy" on Windows Server 2012 HTTP ERROR 404.7 . The moral: IDK, install the whole package even if you don't think you will need some parts of it and skip the express install?