Open janhenckens opened 3 weeks ago
So control-panel access, you shouldn't be accessing it from multiple domains anyway, according to the Craft license. As such, it assumes that the primary site is the one you have "licensed" to run Craft from, and redirects to that.
For front-end requests, it should handle redirecting back to the site you came from.
I'll see what I can do about this, but just wanted to flag that first.
Question
We're running into an issue with Social Login & a multi-domain multisite project - and I was wondering what & where might be happening here.
Here's the setup we have:
Primary site:
project.com
Landing page for Belgium:project.be
Site for Belgium (Dutch):project.be/be
Site for Belgium (French):project.be/fr
Site for France:project.fr
Site for the Netherlands:project.nl
For any of those site, when we visit /admin and click the SSO button (Azure in our case), the callback url comes back as
project.com
(which is the primary site) - instead of any of the ones we started the request from.I found the issue that added multisite support to Social Login (#9) and check that code,
currentSite
simply always returns the primary site.Also created an issue for this in the craftcms/cms repo: #15971, since I'm not sure where the issue is.
Additional context
Craft 4.12.6.1, Social Login 1.0.20