Custom Domains
Docs Preview
This is unreleased documentation for Traefik Hub!
To do: This needs more info
Since a user can configure custom domains for the Gateway and Portal via CRDs, this page needs to be updated!
Custom domains cannot be configured on Kubernetes Edge Ingress CRD
This page explains how to use Traefik Hub with custom domains.
Introduction¶
Custom domains allow you to make your sites accessible at your own domain names (for example, mydomain.dev
)
Before you begin¶
This feature requires you to have:
- Your own domain with DNS records that you can update
- An already published service with Traefik Hub
Implementation details¶
Learn about the differences between domains generated by Traefik Hub and custom ones.
Custom domain¶
When you use a custom domain, Traefik Hub will regularly check the CNAME entry of your DNS.
As soon as the domain is verified, Traefik Hub ill create an Ingress for accessing the service on the entry point of the Traefik Hub agent and will obtain a certificate for your custom domain and protect the ingress with TLS.
This entry point uses by default a secured connection.
With a custom domain, services are accessible via the Traefik Hub tunnel and via the public ClusterIP of the service,
using the websecure
entry point.
Traefik Hub domain¶
If you use a Traefik Hub domain, for example faithful-gayal-agctu4.q4brn06t.traefikhub.io
the service will be reachable only via the Traefik Hub tunnel.
Implementation details¶
Learn about the differences between domains generated by Traefik Hub and custom ones.
Custom domain¶
When you use a custom domain, Traefik Hub will regularly check the CNAME entry of your DNS.
As soon as the domain is verified, Traefik Hub ill create an Ingress for accessing the service on the entry point of the Traefik Hub agent and will obtain a certificate for your custom domain and protect the ingress with TLS.
This entry point uses by default a secured connection.
With a custom domain, services are accessible via the Traefik Hub tunnel and via the public ClusterIP of the service,
using the websecure
entry point.
Traefik Hub domain¶
If you use a Traefik Hub domain, for example faithful-gayal-agctu4.q4brn06t.traefikhub.io
the service will be reachable only via the Traefik Hub tunnel.
Publishing through Custom Domain¶
The custom domain feature is based on DNS records configuration.
Using canonical names, you can forward your domain to the domain Traefik Hub generated for your service.
Custom domains only work for already published services
Find the service you want to publish with your custom domain and get the generated domain.
In your DNS provider, add a CNAME
record pointing your custom domain to the Traefik Hub generated URL,
for example, mydomain.dev
pointing to faithful-gayal-agctu4.q4brn06t.traefikhub.io
.
The generated domain name remains valid unless you unpublish your service.
Field | Description |
---|---|
Domain | The domain you want to use to access your service. Example: service.example.com |
TTL | Time-to-live for DNS caching mechanisms, in seconds. Example: 10800 |
Type | Type of record you are creating for your domain. CNAME only.Example: CNAME |
After the DNS record is set up, go back to the service page and add your domain to the Custom address section and select Save.
Once every step is completed, it may take a few seconds for the system to apply the configuration.
Not Trusted Certificates
Generating a Let's Encrypt certificate for the new domains requires more time than exposing the service. It might end in a window where the service is available with the wrong certificate. During this time, Traefik Hub serves a self-signed certificate.