Deploying .NET with Jenkins/Hudson

一个人想着一个人 提交于 2019-11-29 20:38:24
Anders Lindahl

I've had good experiences with using Web Deploy and as a final build step with Jenkins running a bat file containing:

msdeploy.exe -verb:sync -source:package=%PACKAGE% -dest:auto,ComputerName=%TARGETHOST%

You'll have to install the web deploy package on your build server and the extention on IIS.

I'm using the MSBuild Jenkins plugin to build and then deploy the project. As mentioned in other answers, you need to have Web Deploy installed.

In the project configuration page in Jenkins, you need to add the following to the Command Line Arguments field:

/p:Configuration=Debug /p:DeployOnBuild=true /p:PublishProfile=publishProfileName

Of course, you need to first create the publish profile, either in VS or by exporting it from IIS and you also need to specify the solution file path in the MSBuild Build File field.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!