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

How to add tenant at runtime #38

Open
BernhardGlueck opened this issue Sep 20, 2023 · 4 comments
Open

How to add tenant at runtime #38

BernhardGlueck opened this issue Sep 20, 2023 · 4 comments

Comments

@BernhardGlueck
Copy link

Hi there !

Great work on orchard core and i am thinking of using it for a new SAAS product I am developing.

I have two questions though ( since the docs seem to be not there )

  1. I can add tenants via the configuration file, but how can i add them at runtime ? e.g have an admin area or self registration feature for users ...

  2. Are modules loaded in an assemblyloadcontext and isolated from the main application ?

@agriffard
Copy link
Member

agriffard commented Sep 20, 2023

Do not edit the configuration file directly.

You can manage the tenants from the admin of the default site.

Connected with the admin, enable the Tenants feature and you will have access to the Tenants page.

@BernhardGlueck
Copy link
Author

Thank you, but i am using Orchard Core only as a Module/Multitenancy enabling layer. No Ui whatsoever.
So i don't want to use the predefined Admin Module, but since that module can do it obviously programmatically, i will check that source code to see how it is doing it.

@BernhardGlueck
Copy link
Author

It seems to me that the relevant logic is in: AdminController

@sebastienros
Copy link
Member

You can check what the admin controller is doing in this module, correct. You can also check https://github.com/OrchardCMS/TryOrchardCore which is what we use to let users try orchard core by creating playground websites dynamically. It's available at https://try.orchardcore.net

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

3 participants