Build once and deploy to multiple environments with msdeploy & Visual Studio 2012

前端 未结 4 1364
北恋
北恋 2020-12-04 13:35

Working on centralizing configurations, app settings and connection strings, for multiple solutions, while also switching over to use msdeploy from command line to deploy we

4条回答
  •  一向
    一向 (楼主)
    2020-12-04 14:07

    We use #5 and it works very well. Using MSBuild for publish profiles provides a bunch of flexibility (Items are particularly useful).

    In our deployment pipeline, only the website package, build/beployment targets and publish profiles are made available to deployment stages. Source code, including project files, are only utilised by the build/test stage.

    FYI, we went with publish profiles specifically as you'll quickly run into the problem of keeping environment specific server details / credentials, skip clauses and parameter values together. WPP / Publish Profiles track all these things in the pubxml file, and MSBuild's features allow for some nice convention-over-configuration "helpers" for common-but-"noisy" tasks.

提交回复
热议问题