通过aspnet解决方案创建WDP后, [project name].deploy.cmd文件在执行时返回以下错误: Error Code: ERROR_SITE_DOES_NOT_EXIST More Information: Site 'freedomstoreusa.azurewebs ...
提示:本站收集StackOverFlow近2千万问答,支持中英文搜索,鼠标放在语句上弹窗显示对应的参考中文或英文, 本站还提供 中文繁体 英文版本 中英对照 版本,有任何建议请联系yoyou2525@163.com。
我们有一个Jenkins Pipeline作业设置,可以使用MSDeploy部署到我们的开发环境。 我们已将一个常规文件检入源代码管理中,该文件可运行多个不同应用程序的部署。 然后,每个应用程序都下载并调用此文件。 当MSDeploy遇到诸如错误代码:ERROR_USER_NOT_ADMIN的错误时,作业将按预期失败。 如果有人不满SetParameters.xml文件中的“ IIS Web应用程序名称”,则可以在Jenkins日志中看到错误
15:55:36 Error Code: ERROR_SITE_DOES_NOT_EXIST
15:55:36 More Information: Site 'dev.mysite.com1' does not exist. Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_SITE_DOES_NOT_EXIST.
15:55:36 Error count: 1.
[Pipeline] }
[Pipeline] // withCredentials
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // script
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // timestamps
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline
Finished: SUCCESS
但这项工作仍然成功。
摘自Pipeline Job Groovy:
Stages = load "DeployTo_Test.Groovy"
Stages.Deploy(DROP_FOLDER, PROJECT_NAME, VER_DEPLOY_TO)
摘自DeployTo_Test.Groovy
def Deploy(DROP_FOLDER, PROJECT_NAME, VER_DEPLOYMENT_LOCATION) {
...SetSomeValues
bat "pushd ${COMMAND_LOC_TO_RUN} && ${PROJECT_NAME}.deploy.cmd /Y /M:${deploymentMachines[i]} /U:%DeployUsername% /P:%DeployPassword% -setParamFile:%workspace%\\${SetParamFile}"
}
来自另一个导致作业失败的MSDeploy错误的日志
16:16:48 Error Code: ERROR_USER_NOT_ADMIN
16:16:48 More Information: Connected to 'myMachine.com' using the Web Deployment Agent Service, but could not authorize. Make sure you are an administrator on 'myMachine.com'. Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_USER_NOT_ADMIN.
16:16:48 Error: The remote server returned an error: (401) Unauthorized.
16:16:48 Error count: 1.
[Pipeline] }
[Pipeline] // withCredentials
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // script
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // timestamps
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline
ERROR: script returned exit code -1
Finished: FAILURE
为什么Jenkins \\ MSDeloy bat命令成功退出并出现ERROR_SITE_DOES_NOT_EXIST,如何使它像其他情况一样在此错误上失败?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.