Deploying .NET with Jenkins/Hudson Deploying .NET with Jenkins/Hudson jenkins jenkins

Deploying .NET with Jenkins/Hudson


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.