I am trying to deploy an asp.net MVC site to a remote IIS Server. The deployment work fine in Visual Studio but I want to automate it.
I am using the following MSDeploy Command:
"C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe" -verb:sync -source:package="SportsStore.WebUI.csproj.zip" -dest:iisApp="Default Web Site/SSBuild",ComputerName="http://r2anet01.eastus.cloudapp.azure.com/MSDEPLOYAGENTSERVICE",UserName='Scott',Password='?????',AuthType='Basic' -allowUntrusted
MS deploy returns the following error:
Error Code: ERROR_USER_NOT_ADMIN
More Information: Connected to 'r2anet01.eastus.cloudapp.azure.com' using the Web Deployment Agent Service, but could not authorize. Make sure you are an administrator on 'r2anet01.eastus.cloudapp.azure.com'. Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_USER_NOT_ADMIN.
Error: The remote server returned an error: (401) Unauthorized.
Error count: 1.
I am using the same username/password in MSDeploy that I use in Visual Studio.
Any help would be appreciated.