|
| 1 | +--- |
| 2 | +id: custom_domain |
| 3 | +title: Add custom domain. |
| 4 | +sidebar_label: Custom Domain |
| 5 | +slug: /guides/howto/custom_domain |
| 6 | +description: How to add a custom domain. |
| 7 | +--- |
| 8 | + |
| 9 | +A [Custom Domain](/docs/concepts/custom-domain) let you serve login under your own domain. |
| 10 | + |
| 11 | +This page explains how to add a custom domain. |
| 12 | + |
| 13 | +import Tabs from "@theme/Tabs"; |
| 14 | +import TabItem from "@theme/TabItem"; |
| 15 | + |
| 16 | +## Add the domain |
| 17 | + |
| 18 | +<Tabs |
| 19 | +defaultValue="console" |
| 20 | +values={[ |
| 21 | +{label: 'Console', value: 'console'}, |
| 22 | +]}> |
| 23 | +<TabItem value="console"> |
| 24 | + |
| 25 | +1. In Admin console, navigate to **Branding → Domains**. |
| 26 | +1. Click on **Add Integration**. |
| 27 | +1. In the DNS record, put your chosen custom domain. |
| 28 | + For example: _auth.acme.io_ |
| 29 | +1. Click the **Add** button. |
| 30 | + |
| 31 | +</TabItem> |
| 32 | +</Tabs> |
| 33 | + |
| 34 | +## Domain validation |
| 35 | + |
| 36 | +For security reasons, we have to ensure that you own the domain, |
| 37 | +This requires you to add a TXT record with the given details in your domain entries. |
| 38 | + |
| 39 | +<img src="/img/howto/customdomain_dns_record.png" width="60%"/><br/><br/> |
| 40 | + |
| 41 | +(See below if your DNS provider is Godaddy) |
| 42 | + |
| 43 | +After adding the DNS record, click the **Verify Domain** button. |
| 44 | + |
| 45 | +The domain should be in a _verified_ state. |
| 46 | + |
| 47 | + |
| 48 | + |
| 49 | +## Certificate deployment |
| 50 | + |
| 51 | +For SSL to work, a certificate (with its key) should be provided, |
| 52 | + |
| 53 | +Issuing a certificate is beyond the scope of this tutorial. |
| 54 | + |
| 55 | +Once a certificate issued, you should have a PEM file with a full chain certificate and a key. |
| 56 | + |
| 57 | +In the domains action, click the **deploy** button (see screenshow above). |
| 58 | + |
| 59 | +Provide the certificate and key and click deploy. |
| 60 | + |
| 61 | +If everything is okay, the delpoyment state should be green. |
| 62 | + |
| 63 | +Wait a bit for the deployment process to end. |
| 64 | + |
| 65 | +## Use the domain |
| 66 | + |
| 67 | +Refer to your domain instead of _crossid.io_, for example, if your tenant is _acme_, located in US then |
| 68 | + |
| 69 | +OAuth endpoints would be refered to: _https://acme.crossid.io/oauth2/.well-known/openid-configuration_ |
| 70 | + |
| 71 | +If your custom domain is _auth.acme.io_, your can refer now to the URL: _https://auth.acme.io/oauth2/.well-known/openid-configuration_ instead. |
| 72 | + |
| 73 | +## DNS Providers |
| 74 | + |
| 75 | +### Godaddy |
| 76 | + |
| 77 | +If your domain is hosted in Godaddy follow these steps: |
| 78 | + |
| 79 | +1. Open https://dcc.godaddy.com/manage/acme.io/dns |
| 80 | +1. Put a _TXT_ record with the given _name_ and _value_. |
| 81 | +1. Click the **Add Record**. |
| 82 | + |
| 83 | + |
0 commit comments