We are implementing multi-tenant application .For this we need to assign subdomain for each tenant. How can we achieve this by using TenantSettingAppService.cs ? Also ,can you tell us how can we define tenant-specific settings , and how can we change Setting scope to tenant ?
1 Answer(s)
-
0
Hi,
Current version of AspNet Zero already supports tenant subdomains. But the address for a tenant should contain tenant name like <a class="postlink" href="http://tenant1.mydomain.com">http://tenant1.mydomain.com</a>.
In order to achieve this, you need to set your website address in settings page (the one you see when you login as host admin) http://{TENANCY_NAME}.mydomain.com.
For more information about it select your version here <a class="postlink" href="https://aspnetzero.com/Documents/Development-Guide">https://aspnetzero.com/Documents/Development-Guide</a> and see the WEB SITE ROOT URL part of it.
To define settings for Tenant scope, see <a class="postlink" href="http://aspnetboilerplate.com/Pages/Documents/Setting-Management#DocDefiningSettings">http://aspnetboilerplate.com/Pages/Docu ... ngSettings</a>. You can set it when you are defining it.