How do you deal with connection strings when deploying an ASP.NET site?

后端 未结 11 1006
暗喜
暗喜 2021-02-04 13:51

Right now our test and production databases are on the same server, but with different names. Deploying has meant editing Web.config to change all the connection strings for th

11条回答
  •  闹比i
    闹比i (楼主)
    2021-02-04 14:42

    This kind of task is exactly what build events are designed to address. Think of building as building for a specific target, any target specific configuration should be done there. (with the normal caveat that there are always some exceptions to the rule)

提交回复
热议问题