I am trying to deploy my application using the following msdeploy command:
MSDeploy.exe -source:contentPath="C:\Users\myUser\Documents\ui\dist" -dest:contentPath='c:/inetpub/wwwroot/dist',computerName="https://ec2-xx-xxx-xx-xx.ap-northeast-1.compute.amazonaws.com:8172/MSDeploy.axd?site=Default Web Site",username="administrator",password="XXXXXXXXX",authtype="Basic",includeAcls="False" -verb:sync -allowUntrusted
Getting the following error:
Working...
Info: Using ID '01657062-cece-4713-8dc6-585537b265fd' for connections to the rem
ote server.
>> Error Code: ERROR_DESTINATION_NOT_REACHABLE
>> More Information: Could not connect to the remote computer ("ec2-52-207-222-6
5.compute-1.amazonaws.com"). On the remote computer, make sure that Web Deploy i
s installed and that the required process ("Web Management Service") is started.
Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_DESTINATION
_NOT_REACHABLE.
>> Error: Unable to connect to the remote server
>> Error: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond xx.xxx.xx.xx:8172
I tried the same command for 6 other servers and it worked fine, but not working for 2 of the servers which are configured the same way.
What am i missing ?
Added the rule to security group for port 8172 and it started working. But i have no clue why it was working from Visual studio before and not from command prompt.
To successfully deploy your website on to windows server using Web deploy, make sure the following is in place.
The site names must be exactly matched in both Visual studio and on IIS server
Make sure the sever installed with the same.net framework as your visual studio (e.g ASP, ASP.net 4.5…)
Make sure port 8172 is open on the server(8172 is used for web deploy)
The following step fixed my issue.
While installing web deploy on a windows server, please ensure to select 'Complete' feature installation instead of 'Typical' or 'Custom'. Once installation is done you will be able to deploy an application from visual studio.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With