Deploying the same site N times

时间:2015-10-30 23:26:06

标签: asp.net-mvc wcf web-deployment

With our company, we sell a service to our customers, this is a website which let customers enter some parameters and informations, and then, they can query a web service to get the previous informations computed. These web sites are hosted on our servers. We would have on our servers one database per client (dbo.Client1, dbo.Client2...) with the same schema. And we would like to provide a different url for each client : expl : www.client1.service.com www.client1.ws.com/compute www.client2.service.com www.client2.ws.com/compute But i'm wondering how to deploy easily the web services and the web site? Do i have to deploy one web service and one website per client (with different web config)? And maybe create multiple deployment scripts ? Or is it possible to imagine one instance of each (web service and web site), listening on several addresses, and creating different connection string according to the entry point of the request (is it even possible with MVC or WCF ?) Any other idea ? I don't know what is the best practice here. Thank you.

1 个答案:

答案 0 :(得分:0)

如果有人有一天读到这个问题,我使用多租户解决方案来解决我的问题,这允许我只部署一个站点实例。

网站处理webrequest,并根据主机连接到不同的数据库。