Document multi-domain custom UI URLs
Closed this issue · 2 comments
Preflight checklist
- I could not find a solution in the existing issues, docs, nor discussions.
- I agree to follow this project's Code of Conduct.
- I have read and am following this repository's Contribution Guidelines.
- This issue affects my Ory Network project.
- I have joined the Ory Community Slack.
- I am signed up to the Ory Security Patch Newsletter.
Related issue: ory/network#218
Document content
The Ory Network has the ability to configure custom UI URLs per custom domain.
For example when I have multiple custom domain on a singular project auth.example.com
and cname.foobar.com
I would like to configure a custom UI for each TLD example.com
and foobar.com
.
In the past this was not possible due to the Custom UI only accepting a singular URL per flow, e.g. login
flow had only one URL on the project. Relative URLs were also not a solution since the cname would adopt the relative URL. auth.example.com
-> login flow with /login
relative URL would result in https://auth.example.com/login
which will not work! A custom domain added to a project can only point to the project and not to another service hosting the UI!
With these new changes the Custom UI page on the console will allow selecting the custom domain and setting a custom ui base url
. This URL will then map on top of any absolute or relative url the project has already configured.
For example:
Custom UI Base URL: https://custom-domain.com/auth
Login URL: https://my-ui.com/login
Registration URL: /registration
Will map accordingly:
Login -> https://custom-domain.com/auth/login
Registration -> https://custom-domain.com/auth/registration
.
NOTE: When setting the Custom UI Base URL the Account Experience will be inaccessible for that particular custom domain. Other custom domains will still function correctly.
The normal <project-slug>.projects.oryapis.com
will redirect to the first cname it knows of.
On the Ory CLI tunnel setting the ORY_SDK_URL
or ORY_KRATOS_URL
environment variable to your custom domain that has a custom base URL set will result in the tunnel redirecting to the custom base URL. It is best to use the project-slug for the Ory CLI tunnel to always work correctly.
Additional Context
This is not released yet, but will be coming soon!
done