Serve a Tunnel on your own hostname
Point a hostname you own at an Identity's Tunnel with two CNAME records.
Not served yet. This page describes Custom Domains as they will work once serving ships. Today a hostname can be claimed and its two records shown and set, but no certificate is issued and no Custom Domain is served until that half ships; checking the records answers custom_domain_verification_unavailable until then.
A Custom Domain serves an Identity's Tunnel on a hostname of your own: tunnel.customer.com in place of orderbot.tigbywire.eu. Tigby serves it over HTTPS with a certificate of its own for that hostname, and raw TCP by SNI reaches it the same way the Tunnel hostname does.
Before you start
- A subdomain, never the domain itself. The hostname points at the Tunnel with a CNAME, and the
apex of a zone (
customer.com,customer.co.uk) cannot carry one. An apex is refused withapex_not_supported; whether a name is an apex is decided against the Public Suffix List, not by counting labels, sotunnel.customer.co.ukis fine. - A Plan that carries them. Custom Domains are counted per Org: Max carries ten, Enterprise by agreement, Free and Pro none. Past the limit a create is refused with
custom_domain_quota_exceeded. - Write access to the zone. You set two records in your own DNS. Tigby never writes to your zone.
Claim the hostname
On the Identity's page in the console, under Custom Domains, or:
tigby domain create tunnel.customer.com --identity orderbotOver REST it is POST /api/identities/{handle}/custom-domains with {"hostname": "tunnel.customer.com"}. The answer is the domain in pending_dns with the two records to set. Every read of the domain names them again, so you never need the create's answer to find them.
Set the two records
Both are CNAME records in your own zone:
| Name | Value | What it does |
|---|---|---|
tunnel.customer.com | orderbot.tigbywire.eu | Points the hostname at the Identity's own Tunnel hostname. |
_acme-challenge.tunnel.customer.com | <token>.acme.tigbywire.eu | Proves the hostname is yours, and lets Tigby answer the certificate challenge for it. |
The token is the domain's own: 32 hex characters, different for every domain and every Org. Copy both values from the console or from tigby domain list --identity orderbot; do not type them.
The second record is the whole proof of control. There is no separate TXT step, and Tigby creates no record anywhere when it checks: the challenge CNAME already carries the token. When a certificate is issued, the only record ever written is a short-lived TXT at <token>.acme.tigbywire.eu, in Tigby's own zone, which exists for the length of one issuance run.
Because one name carries one CNAME, a second Org that claims the same hostname can never prove it while yours points at your token; its check is refused with custom_domain_claimed.
The status chain
A domain normally walks pending_dns → verified → active. Three more statuses say what went wrong on the way, and each of them heals without anything for you to do once the cause is gone.
| Status | What it means |
|---|---|
pending_dns | Created. Waiting for both records to check out. |
verified | Both records check out and CAA allows Let's Encrypt. No certificate yet: it is issued on the next hourly run. |
active | A certificate is held on both of Tigby's servers, and the hostname is served over HTTPS. |
issuance_failed | A certificate run failed. The CA's own words are on the domain as last_acme_error, and every hourly run tries again; the first that succeeds makes it active. |
dns_broken | The daily re-check found the records changed. Serving goes on for seven days from that moment (dns_broken_at). |
suspended | The records stayed broken for seven days. The hostname is no longer served and its certificates are dropped. |
A dns_broken domain heals to the status it broke from (active for a domain that was being
served) as soon as the records check out again. A suspended domain heals only as far as
verified, because a suspension stops renewal and can outlast the certificate; from there the next
hourly run certifies it again, as for a new domain.
How long each step takes
- Checking the records. A
pending_dnsdomain is checked every minute for its first hour and every fifteen minutes after that, for seven days from its creation. After that only an explicit check moves it:tigby domain verify tunnel.customer.com --identity orderbot, Check now in the console, orPOST /api/identities/{handle}/custom-domains/{hostname}/verify. A check that finds the records wrong is refused withcustom_domain_dns_mismatch, naming what it found at each name. - From
verifiedtoactive: within the hour. Certificates are issued by each of Tigby's two servers on its own hourly timer, never by the check itself, so that the two never answer the same challenge at the same moment. A domain that has just becomeverifiedis not stuck; it becomesactiveonce both servers have run, which is within the hour. - Renewal starts thirty days before a certificate ends and runs on the same hourly timer.
- The daily re-check. Every domain past
pending_dnshas its records checked once a day. The first failure makes itdns_broken; still failing seven days later, it issuspended. - Deleting a domain stops Tigby serving it (at once, or within five minutes on a server that missed the change), frees the hostname to be claimed again, and each server drops its certificate within the hour.
What becomes public
When Tigby obtains a certificate for your hostname, the hostname is submitted to Let's Encrypt, operated by the Internet Security Research Group in the USA (the certificate authority Tigby chose for Custom Domains) and, like every publicly trusted certificate, the certificate naming it is published in Certificate Transparency logs, where anyone can read it and from which it is never removed, also after you delete the domain.
Each of Tigby's two servers holds a certificate of its own, so each issuance and each renewal puts two certificates in the logs, one per server. This happens because you asked Tigby to serve that hostname, and only once its records are verified: a hostname that is claimed and never verified goes to no certificate authority. From the moment you claim it, the hostname is looked up through the public resolver of DNS4EU, operated by Whalebone s.r.o. in the Czech Republic.
Nothing but the hostname reaches either. The privacy policy (§ 5) and the data processing agreement (§ 11) say the same.
CAA: which CA may certify your hostname
A CAA record says which certificate authorities may issue for a name. Certificates for Custom Domains come from Let's Encrypt, and a CAA record that leaves Let's Encrypt out makes every issuance fail. The check looks for it before a domain becomes verified, on the hostname and, failing a record there, on each name above it up to the registrable domain (RFC 8659): a set that excludes Let's Encrypt is refused with caa_forbids_issuance.
A CAA record added after verification is not caught there; the next run fails, and the domain lands in issuance_failed with the CA's words until the record allows it again.
We recommend one CAA record on the hostname itself:
tunnel.customer.com. CAA 0 issue "letsencrypt.org"The challenge CNAME delegates the certificate challenge for your hostname to Tigby's zone. That is what lets Tigby renew without touching your DNS, and it also means that whoever controls that delegated name could obtain a certificate for your hostname from any CA that issues on a DNS challenge. A CAA record naming Let's Encrypt alone narrows that to the one CA Tigby uses, and it sits in your zone, under your control; it is the one control that bounds what the delegation can be used for.
Take the challenge CNAME out and the delegation ends with it.
Remove a hostname
tigby domain delete tunnel.customer.com --identity orderbotIt asks for confirmation on a terminal and needs --yes elsewhere. The console's Remove asks the same. Take the two records out of your zone afterwards; Tigby does not touch them. Deleting the Identity, or the Org, takes its Custom Domains with it the same way.
Events
Each step of the chain is an Event a Webhook can subscribe to: custom_domain.verified, custom_domain.certificate_issued, custom_domain.certificate_failed (with the CA's error), custom_domain.dns_broken (with both records as found) and custom_domain.suspended. A heal of dns_broken raises none, and neither does a renewal.