Automated Deployment with TFS 2010

Posted by I'm in o-HI-o on January 20, 2011
The automated/continuous deployment process can be performed in Team Foundation Server 2010 via MSBuild. We can tell MSBuild to ‘deploy on build’ which causes MSBuild to make a call to MSDeploy. To assist MSBuild in working with MSDeploy, we can specify parameters at Build Process Definition Time that are passed through to MSDeploy (see image)

<div>In the MSBuild argument property of the Build Process parameters, the following are parameters that were used to automate the deployment of a sample project . Notice the parameters that are to be passed to MSDeploy start with “MSDeploy*”.</div> <div> </div> <div> </div> <div></div> <div>/p:DeployOnBuild=True –> tells MSBuild that it will need to build a deployment package</div> <div>/p:Configuration=Debug –> tells MSBuild which configuration to merge to the Web.config</div> <div>/p:DeployTarget=MSDeployPublish –> tells MSBuild to call MSDeploy for deployment</div> <div>/p:MSDeployPublishMethod=RemoteAgent –> tells MSDeploy how to perform the deployment</div> <div>/p:MSDeployServiceUrl=http://[deployment target]/msdeployagentservice’’ -> tells MSDeploy who to talk to when doing a deployment</div> <div>/p:username=username -> user account for build/deploy process</div> <div>/p:password=password</div> <div></div>