Take the rebrand/dual-domain branch live as two sites from one repo, replacing
the current GitHub Pages production site with two Cloudflare Pages projects:
- imqueue.org — open-source "Terminal" edition (docs, tutorial, API, blog)
- imqueue.com — commercial "Flux" edition (home + pricing/license form)
- imqueue.net — 301 → imqueue.com
Context / confirmed: production imqueue.com is served by GitHub Pages
(.github/workflows/deploy.yml, CNAME, .nojekyll), with the domain already in
Cloudflare (proxied → free SSL + CDN/WAF). We fully replace GitHub Pages with
Cloudflare Pages. The old deploy.yml is incompatible with the new multi-edition
build (it builds _site, but editions output _site-org/_site-com and need the
EDITION env), and GitHub Pages can only serve one site — so it is retired here.
The same Cloudflare zone stays — SSL, caching, WAF/DDoS all continue. The only
DNS change is the record target: GitHub's IPs (185.199.108–111.153) → a proxied
*.pages.dev CNAME. Pages provisions the custom-domain cert automatically.
Strategy: branch-first. Point the Pages projects at rebrand/dual-domain,
verify on *.pages.dev, then switch DNS. This decouples the DNS cutover from the
git merge, so downtime is a few seconds (both old + new serve valid sites) and
rollback is trivial. The merge to master becomes a cosmetic final step.
Cloudflare → Workers & Pages → Create → Pages → connect this GitHub repo, twice:
| Project | Production branch | Build command | Output dir |
|---|---|---|---|
imqueue-org |
rebrand/dual-domain |
npm run build:org |
_site-org |
imqueue-com |
rebrand/dual-domain |
npm run build:com |
_site-com |
- Node version comes from
.nvmrc(20). No other build config needed. - On
imqueue-com→ Settings → Environment variables, addRESEND_API_KEY(Production + Preview). Optional:CONTACT_TO(default[email protected]),CONTACT_FROM(default@imqueue <[email protected]>). - Verify both on their
imqueue-org.pages.dev/imqueue-com.pages.devURLs. (imqueue.com is still served by GitHub Pages this whole time.)
- Resend → create account → add & verify the
imqueue.comdomain (add the SPF/DKIM DNS records it gives you, in Cloudflare). Required to send from[email protected]. Put the API key in step A. - Cloudflare → Email Routing on imqueue.com → forward
[email protected]to a real inbox you monitor.⚠️ Enabling Email Routing rewrites the domain's MX records. If imqueue.com already receives email elsewhere, reconcile that first.
- Smoke-test after DNS cutover: submit the pricing form → confirm mail at support@.
- imqueue.com →
imqueue-comproject → Custom domains → addimqueue.com(andwww.imqueue.com). Cloudflare replaces the GitHub PagesArecords with a proxied CNAME →imqueue-com.pages.dev. Manually delete any leftover185.199.x.xA/AAAArecords on@. SSL provisions automatically. - imqueue.org → add the zone to Cloudflare if not already →
imqueue-orgproject → add custom domainimqueue.org(+www). - imqueue.net → add the zone to Cloudflare → add a proxied placeholder record
(
A @ → 192.0.2.1, orange cloud; same forwww) so it resolves → Rules → Redirect Rules: when host isimqueue.net/www.imqueue.net, 301 tohttps://imqueue.com+ the original path. - Keep SSL/TLS mode = Full (strict) on all zones.
- Verify live:
- imqueue.com → Flux home;
/pricing/submits and emails support@. - imqueue.org → Terminal home; docs / tutorial / API render.
imqueue.com/docs/,/tutorial/,/api/, etc. → 301 to imqueue.org (viasrc/com/_redirects; note/api/contactis a Function and is unaffected).imqueue.net→ 301 → imqueue.com.- Theme toggle, favicons, GA + Clarity work on both.
- imqueue.com → Flux home;
- Submit both sitemaps in Google Search Console:
https://imqueue.org/sitemap.xmlandhttps://imqueue.com/sitemap.xml.
- GitHub repo → Settings → Pages → Source = None (stops GitHub Pages serving).
deploy.yml,CNAME, and.nojekyllare already removed on this branch, so they disappear frommasterat merge (until then,masterkeeps serving the current live site normally).- Merge
rebrand/dual-domain→master. - Switch both Pages projects' production branch to
master(visually a no-op; future pushes to master auto-deploy).
- Before merge: nothing to undo — DNS can be pointed back at GitHub's IPs, and GitHub Pages is still enabled until step D.1.
- After merge: revert the merge commit on
master; Cloudflare redeploys the prior state. Redirect rules and Email Routing can be toggled off independently.