web.config transformation + msdeploy - keeping production passwords out of source control
问题 Our web.config needs a database password. How can we specify this password while building the msdeploy (aka Web Deploy) package or when actually deploying? We build the msdeploy package using msbuild (/p:DeployOnBuild=true) and web.config transformations for environment-specific details. 回答1: Web.config transformations are, by design, build time transformations. I tend to only use them for "everything but debug" changes. What you want is an MSDeploy parameter. Assuming you are using a pubxml