0

Using a publish profile creates a deploy.cmd and a single SetParameters.xml for calling via msdeploy.

Having multiple environments, I'm looking for how to populate version-specific ProjectName.SetParameters.xml files, such that during deployment the corresponding one can be used.

I'd like to create one of these files per environment, to be source-controlled.

Is there an intrinsic way to control the creation of several SetParameters.xml in this manner, or does this need to be a post-build task transforming from a list of per-environment settings?

disassemble-number-5
  • 955
  • 3
  • 11
  • 25

1 Answers1

1

Is there an intrinsic way to control the creation of several SetParameters.xml in this manner, or does this need to be a post-build task transforming from a list of per-environment settings?

According to your description, the following thread provide 5 options, I would suggest that you could select option1, which create a parameters.xml file in your web project and will declare additional Web Deploy parameters.

When you build the Web Deploy package the parameters declared in parameters.xml are created in the package. When this web deploy package is created the web.config file will be transformed based on the build config.

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

For more information about Custom Parameterization, please refer to: https://www.asp.net/web-forms/overview/deployment/web-deployment-in-the-enterprise/configuring-parameters-for-web-package-deployment

Community
  • 1
  • 1
Zhanglong Wu - MSFT
  • 1,652
  • 1
  • 7
  • 8