3

I am getting 401 error when trying to deploy remotely. Event log from server -

The following information was included with the event: 

IISWMSVC_AUTHORIZATION_SERVER_NOT_ALLOWED


Only Windows Administrators are allowed to connect using a server connection. Other users should use the 'Connect To Site or Application' task to be able to connect.

Process:WMSvc
User=deployer

I am using following script to deploy

msdeploy.exe -verb:sync -source:package=c:\Jenkins\workspace\Myproject.zip -   dest:auto,wmsvc=[server_ip],usernverame=iis_deployer,password=iis_deployer,authType=basic -setparam:name='IIS Web Application Name',value='Default Web Site\myproject\master' -allowUntrusted 

It works fine if I use the admin user. But it fails for non-admin and IIS users.

I have tried to set the permission and delegated rules by following this article- https://blogs.iis.net/krolson/using-iis-manager-accounts-for-web-deployment-tool-msdeploy-delegation

Nothing seems to work.

1 Answer 1

2

I have been struggling with this error for hours and I found the solution. In the MsDeploy.exe command line you must specify the site name in the "wmsvc" parameter. For instance:

"C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe" -source:package='d:\temp\xxx.zip' -dest:auto,wmsvc="https://192.168.XXX.XXX:8172/msdeploy.axd?site=Test",userName='usr',password='pwd',includeAcls="False" -verb:sync -disableLink:AppPoolExtension -disableLink:ContentExtension -disableLink:CertificateExtension  -AllowUntrusted -retryAttempts=2 -setParam:'IIS Web Application Name'='Test'
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.