Multi-tenancy with domain based routing #2081
Replies: 1 comment
-
|
Hey, that's an interesting use case! I think to implement this, a routing structure like While you can theoretically configure additional rewrites with the If you do that, in order to be able to provide a locale to APIs from Closely related to this, But yes, this is surely a supported use case—hope this helps! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm looking to migrate to
next-intl, but I'm not sure if my client current use case is compatible. Here is a quick summary:We have 2 domains, say
foofrench.caandfooenglish.ca. We dont use any pathname prefixes, locale is defined based on domains only. At first after looking at the documentation, I was thinking about something like the following:Now, the tricky part where I'm not sure how it can be configured and if it is even supported. We have multi-tenants that can be accessed in both language (ex.
tenant1.foofrench.caandtenant1.fooenglish.caboth works and is displayed in specific locale). We also have a main website that also works for both language (ex.www.foofrench.caandwww.fooenglish.ca)There are many tenants and this is quite dynamic, so I cannot add them all hardcoded in the configuration.
Is there a way to specify a wildcard or something for the domain part maybe (ex.
domain: "*.foofrench.ca",)?Beta Was this translation helpful? Give feedback.
All reactions