Azure Web App Deployment Parameters for MSBuild (TeamCity Example)

Setting up automated publish steps on CI servers often requires setting up an MSBuild step to auto-deploy your application into an Azure Website. While you usually provide a .pubxml publishing profile for that, you also need to add MSBuild parameters for the publishing to work correctly.

My example here is with TeamCity, but it would work similarly with Jenkins or TFS.


MSBuild parameters
 /p:Configuration=Release /p:DeployOnBuild=true 
/p:PublishProfile=MyProjectPublishProfileName /p:UserName=$MyProjectUsername 
/p:Password=XXXXX /p:AllowUntrustedCertificate=true 
/p:VisualStudioVersion=12.0 /p:_DestinationType=AzureWebSite

Don’t omit the $ in the username!

Happy Deploying!

Leave a Reply

Your email address will not be published. Required fields are marked *