Can I use Web Config Convert when publishing to azure with Visual Studio 2012?

I have three environments for my asp.NET mvc application Local, Development and production. This means that I need three webconfig files. The conversion seems to work just fine with local and development deployments through the build server, but not with production deployments. It works when I manually publish a site from visual studio 2012.

Does it have anything to do with services for various environmental conditions?

+6
source share
1 answer

If you intend to use Azure, you can use publishing profiles. The trick is to link your configuration files to your environment settings in Visual Studio.

Here is an overview of publication profiles: http://msdn.microsoft.com/en-us/library/ff398069.aspx

And Scott Hanselman looks through a series of scripts with chains of configuration files: http://www.hanselman.com/blog/TinyHappyFeatures3PublishingImprovementsChainedConfigTransformsAndDeployingASPNETAppsFromTheCommandLine.aspx

With these two parts, there is enough information to not only manually convert the configs, but also to work with them in CI.

Hope this helps, welcome.

+13
source

All Articles