Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create admin user with tenant admin role #99

Open
TechAspirant opened this issue Dec 19, 2023 · 1 comment
Open

Create admin user with tenant admin role #99

TechAspirant opened this issue Dec 19, 2023 · 1 comment

Comments

@TechAspirant
Copy link

Hello,

I'm looking for guidance on creating a Tenant Admin User with the Tenant Admin Role for each new Tenant that gets created. I'm specifically referring to the Example4.MvcWebApp.IndividualAccounts project. How can I achieve this?

@JonPSmith
Copy link
Owner

Hi @TechAspirant,

Let me say back to you on what you are asking. You want every Tenant should have a Tenant Admin User - is that correct? If so here are two suggestions which relay on you create a "Tenant Admin" role (see Example4 for an example).

  • If you use the SignUpAndCreateTenant feature (see this article or this document), then you can make the user signing in to have the "Tenant Admin" role. This is the typical approach.
  • If you want a App Admin to create a new Tenant, then after the Tenant is created you need to add a user for the Tenant and give them the "Tenant Admin" role. See this article or document.

I also recommend you read the Building ASP.NET Core and EF Core multi-tenant apps – Part2: Administration which gives a good overview of administration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants