Harthelm Docs

hart domain

Custom domains of the team: add, verify, route

Generated from cmd/hart at v1.5.0

Custom domains give workspaces your own address. Add the domain, set the DNS record it shows, let it verify, then route paths to workspaces. Changes need the team admin role.

hart domain [flags]
hart domain [command]

Examples:

hart domain add shop.example.org
hart domain verify shop.example.org
hart domain route shop.example.org /=123 /api=124,125

Subcommands:

hart domain add

Adds the domain, unverified, and shows the DNS records to set: the TXT record proves it is yours (only the TXT record does), the CNAME or A record sends its traffic to Harthelm. Then run hart domain verify. A domain that is not verified within a few days is removed again, and a team adds only a few domains an hour. --restricted lets only team members (signed in, or with an API key) reach the domain.

hart domain add DOMAIN [flags]
FlagDescription
--restrictedonly team members may reach the domain

hart domain delete

The domain stops being served; its certificate and edge objects are pruned. Asks first unless --yes is given.

hart domain delete DOMAIN [flags]

Aliases: delete, remove, rm.

FlagDescription
-y, --yesdo not ask for confirmation

hart domain list

List the team's custom domains

hart domain list [flags]

hart domain route

Without routes, shows the domain's routes. With routes, replaces ALL of them with the ones given, in this order (the first match wins): a path prefix such as / or /blog (or an RE2 expression when the domain uses regex), and the workspaces to send it to. Several workspaces on one route split the visitors evenly, which makes A/B tests and blue/green switches. --clear takes the domain off the air.

hart domain route DOMAIN [PATH=WORKSPACE[,WORKSPACE...]]... [flags]

Examples:

hart domain route shop.example.org /api=124 /=123
hart domain route shop.example.org /=123,125
FlagDescription
--clearremove all routes

hart domain set

Changes the settings you name: --restricted, --regex (routes are RE2 expressions), --max-body-bytes and --timeout-seconds (0 restores the installation's default).

hart domain set DOMAIN [flags]

Examples:

hart domain set shop.example.org --restricted=false --max-body-bytes 10485760
FlagDescription
--max-body-bytes intthe largest request body the router passes on (0: the default)
--regexroute paths are RE2 expressions instead of prefixes
--restrictedonly team members may reach the domain
--timeout-seconds inthow long the router waits for a response (0: the default)

hart domain show

Show a domain with its DNS records and routes

hart domain show DOMAIN [flags]

hart domain verify

Asks the platform to look for the TXT record and, unless --no-wait is given, waits for the answer. Verified domains are checked again daily: when the record stays missing for some days, the domain lapses and serves nothing until a check finds it again. Another check within 10 seconds is refused (429).

hart domain verify DOMAIN [flags]
FlagDescription
--no-waitreturn at once, without the result of the check
--timeout durationhow long to wait for the check (default 1m0s)

On this page