开发者

Setup Project for a Web Application

I have a Setup Project that is creating an installation for an extension of a Web Access (like outlook web access of tfs web access).

The problem is the installation is replacing the original we开发者_StackOverflowb.config, instead adding/changing corresponding attributes or nodes.

Someone knows how I should create this Setup Project?

Sebastian


There is no automatic way of doing this. One solution is to rename the web.config in your setup project to something like "web.config.update".

Create a console application which reads in web.config and web.config.update and merges them to a new web.config. Add this application to the setup project and make it run after the install is complete.

But if you are using VS2010 then @Oded´s solution is a better one. Keep a copy of your environments config files inside the project and have the build task transform them for you.


Visual studio 2010 introduced web.config transforms that help with such deployment problems.

See this howto video on how it works.

This will still replace the web.config, however, with the values you specify for the environment.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜