Skip to content

DNS & domains

strad’s public hostnames are custom domains pointed at a DigitalOcean App Platform app, with the TLS certificate issued by App Platform itself. DNS is managed in Cloudflare, DNS-only (grey cloud) — Cloudflare is not proxying the gateway.

EnvironmentHostnamePoints at
Stagingstaging.strad.tadasant.comstrad-staging-wy9v5.ondigitalocean.app
Prodstrad.tadasant.comstrad-prod-qple6.ondigitalocean.app
These docsdocs.strad.tadasant.comstrad.pages.dev (Cloudflare Pages)

The gateway hostnames are DNS-only; the docs hostname is proxied. That difference is load-bearing — App Platform can only issue its own certificate if it sees the real TLS handshake, while Pages needs the orange cloud to serve one.

gateway.publicUrl is not cosmetic. It builds the OAuth redirect URI (…/console/oauth/callback) and the authorize_url in every 424 response. If the hostname is wrong, OAuth and the fail-closed hints break, so it must match the domain App Platform serves.

  1. The domain is passed into the App Platform spec as a PRIMARY domain (via render-spec --domain=<host>, defaulted from gateway.publicUrl). Omit it and the app falls back to its *.ondigitalocean.app hostname.
  2. In Cloudflare, a DNS-only record CNAMEs the hostname at the App Platform app. Cloudflare does not proxy — App Platform terminates TLS, and it can only do that if it sees the real handshake.
  3. App Platform issues and renews the certificate for the custom domain.

The default region is nyc.

The docs are the one hostname Cloudflare does proxy, because Pages terminates TLS at the Cloudflare edge rather than at an origin.

SettingValue
Pages projectstrad, connected to tadasant/strad, production branch main
Root directorydocs
Build commandnpm ci && npm run build
Build outputdist
Env varSITE_URL = https://docs.strad.tadasant.com (production and preview)
DNSCNAME docs.strad → strad.pages.dev, proxied (orange cloud)

Every branch gets a preview deployment, so a PR that changes the docs can be read before it merges.

SITE_URL overrides the site value in docs/astro.config.mjs, which is what Astro uses to build canonical URLs and the sitemap. The fallback in that file is the same hostname, so an unset SITE_URL still produces a correct site — but pin it anyway, so the code and the deployment can’t drift apart silently.

Preview deployments get a per-branch *.pages.dev hostname while SITE_URL stays fixed, so a preview build emits canonical URLs pointing at production. That is harmless for previews and expected.