visual studio - Web Deploy returns 401 unauthorized when publishing via [proj].deploy.cmd -


i'm having bit of problem web deploy can't seem iron out. every time try , publish wmsvc via [proj].deploy.cmd command in package i'm getting "the remote server returned error: (401) unauthorized". command looks (project called "web", server named "autodeploy"):

web.deploy.cmd /y /m:https://autodeploy:8172/msdeploy.axd -allowuntrusted 

i can publish fine https://autodeploy:8172/msdeploy.axd via visual studio service running , can authenticate administrator. running locally on machine against package while logged on administrator (it's little local win 2k8 vpc) isn't working , adding /u , /p parameters administrator account nothing.

i've enabled failed request tracing , getting this output @ least there's refer unfortunately can't determine root cause is. i'm trying connect same service same credentials in visual studio different.

just out of interest, can publish fine web deployment agent service (msdepsvc) follows:

web.deploy.cmd /y /m:http://autodeploy/msdeployagentservice /u:autodeploy\administrator /p:... 

but want wmsvc running! thoughts?

sayed's comment above got me pointed in right direction. after making build output verbosity "detailed" , setting usemsdeployexe true in .csproj (another tip sayed's blog), found command generated visual studio setting authentication type basic retrospectively, obvious given plain text username , password.

the msdn post on how to: install deployment package using deploy.cmd file explains can add "a" flag command set this. in short, here's how looks (and works):

web.deploy.cmd /y /m:http://autodeploy/msdeployagentservice /u:autodeploy\administrator /p:...  /a:basic 

Comments

Popular posts from this blog

android - Spacing between the stars of a rating bar? -

aspxgridview - Devexpress grid - header filter does not work if column is initially hidden -

c# - How to execute a particular part of code asynchronously in a class -