Multi-Tenant (w/ subdomains)
Last updated
Was this helpful?
Last updated
Was this helpful?
The Multi-Tenant w/ Subdomains mode works similarly to the strategy, but each workspace is accessed via its subdomain.
The term workspace is just a label, you can to anything you find appropriate to your business model. Examples are Organizations, Companies, Teams, etc.
Each workspace has its own , , , and .
After a new user signs up via the root domain, they are asked to create a new workspace and assign a subdomain to it.
The user will be set as admin and redirected to the workspace's subdomain.
Users that sign-up via the subdomain are accessing a workspace that already exists and already has an admin.
In this case, new users will need the admins' approval to join.
You can override this behavior on the code and assign default permissions for users.
The file that contains this logic is backend/src/services/auth/authService.ts
.
Read the section for more details.
If users came to the subdomain by , they will have the roles the admin previously assigned to them. In that case, they will go straight to the application.
Users can switch, create, edit or delete workspaces on the Workspaces page that can be accessed via the User's menu. Permission to edit and delete a specific workspace depends on the the user has on that workspace.