加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 编程开发 > asp.Net > 正文

asp.net – 部署在Visual Studio中正常运行,无法使用MSDeploy

发布时间:2020-12-16 09:41:07 所属栏目:asp.Net 来源:网络整理
导读:我有一个Web项目,我希望它使用MSDeploy将其部署到临时环境. 从Visual Studio发布一切正常使用这些设置: 服务器:mystaging.com 站点名称:项目暂存(我删除了默认网站,这是我的暂存IIS中唯一的站点) 用户名:管理员 密码:SomePasswordHere 目的地:mystagin
我有一个Web项目,我希望它使用MSDeploy将其部署到临时环境.

从Visual Studio发布一切正常使用这些设置:
服务器:mystaging.com

>站点名称:项目暂存(我删除了默认网站,这是我的暂存IIS中唯一的站点)
>用户名:管理员
>密码:SomePasswordHere
>目的地:mystaging.com

(mystaging.com是一个公共站点 – 显然不是这个)

部署从Visual Studio完美运行.

从MSDeploy尝试相同的事情,如:

-verb:sync 
-allowUntrusted
-source:contentPath="C:Users...objStagingPackagePackageTmp" 
-dest:contentpath='C:inetpubwwwrootproject-staging'
    includeAcls='False',ComputerName=https://mystaging.com:8172/msdeploy.axd?site=project-staging,UserName=Administrator,Password=SomePasswordHere,AuthType=Basic

失败了:

Error Code: ERROR_USER_UNAUTHORIZED
More Information: Connected to the remote computer ("mystaging.com") using the Web Management Service,but could not authorize. Make sure that you are using the correct user name and password,that the site you are connecting to exists,and that the credentials represent a user who has permissions to access the site.  Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_USER_UNAUTHORIZED.
Error: The remote server returned an error: (401) Unauthorized.
Error count: 1.
Process exited with code -1

我已经尝试了一切(提升权限,让其他用户等等)并没有任何效果.

有人可以给我一个如何解决这个问题的提示,并让部署也可以从MSDeploy开始工作吗?

解决方法

您是否有权访问目标部署服务器以分析应用程序,安全性和Web服务器日志?钻研这些,搜索上次失败的部署尝试的日期和时间可能会更多地指示出现了什么问题.

编辑:纠正错字

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读