Skip to content

feat: the console asks for no domain — the domain is set later - #365

Merged
ruehowl merged 4 commits into
mainfrom
claude/brave-mccarthy-4l2qxb
Oct 22, 2026
Merged

ruehowl merged 4 commits into
mainfrom
claude/brave-mccarthy-4l2qxb

Conversation

@ruehowl

@ruehowl ruehowl commented Oct 22, 2026

Copy link
Copy Markdown
Contributor

The product answers on workers.dev from its first deploy, every phase probes workers.dev, and the one component that attaches a domain (cloudflare-domain) ships parked, so nothing in the build needs a domain. With this change the console card stops asking for one. Everything that uses the domain stays where it is and carries a placeholder until an owner sets it. Same change as turso-starter #9.

It goes in the same release as #364: baseline-v4 was never pushed, and it gets pushed at this PR's merge commit.

What changes

  • Card (blueprint.yaml): the productdomain input is removed. apibaseurl is removed too, because it was derive: "https://api.{productdomain}" and a card can only derive from inputs it declares.

  • Build (repo-blueprint.yaml): productdomain is optional with default "". A hand-run build can still pass --set productdomain=. repo-blueprint.yaml keeps apibaseurl (default empty).

  • Rebrand: productdomain is no longer required. When it is empty, the reserved placeholder <reponame>.example.com (RFC 2606) goes everywhere sourceplane.ai stood as the product domain:

    • intent's BASE_DOMAIN and CONSOLE_CUSTOM_DOMAIN, plus the parked cloudflare-domain's baseDomain
    • api-edge's CONSOLE_CUSTOM_DOMAIN
    • identity-worker's OAUTH_ALLOWED_CONSOLE_ORIGINS, which still lists the workers.dev console, so sign-in keeps working
    • the notifications sender
    • billing's POLAR_SUCCESS_URL
    • the CORS test fixtures

    Company mailboxes stay protected. No component logic changed. The Supabase root sets no auth URLs.

  • CLI default API:

    • With no domain, it is the product's own prod edge, https://<brandSlug>-api-edge-prod.<subdomain>.workers.dev. This follows the worker-name rule for api-edge deployed --env prod.
    • With a domain given, it stays https://api.<domain>.
    • An explicit apibaseurl still overrides both.
  • cloudflare-domain (the bug found in cirrus fix(supabase): use versioned secret names to avoid deletion conflicts #32): baseDomain/workerNamePrefix and their Terraform defaults already named sourceplane.ai / sourceplane-web-console-next. Its README examples did not: they named multi-tenant-saas.app and multi-tenant-saas-web-console-next, which the rebrand turns into <reponame>.app, not the placeholder. They now name the baseline's own identity, so all of them follow the placeholder and the console Worker. Nothing asks an owner to set them by hand.

  • Shipped ai/context/operations.md: new section "Setting the domain later". It lists every place the domain goes, then the steps:

    1. Replace the placeholder (git grep -lF).
    2. Create the zone and restore the commented-out subscribe block.
    3. Verify the mail domain.
    4. Check Supabase auth URLs (none are set).
    5. Optionally re-point the CLI default.
    6. Merge, then run the docs flow.
  • hooks/render-deployment-docs.sh: an empty domain already skipped the custom-domain probes. The placeholder now counts as no domain too, and the stale "phase 07" text is gone.

  • Tests:

    • The fixture carries no domain.
    • placement.test.sh used to read the card's derive. It now checks the placed product directly: its DEFAULT_API_URL must match the branded api-edge's prod worker on workers.dev, and its intent must carry the placeholder. It refuses to pass when there is nothing to check.
    • rebrand.test.sh gains 9 checks: no domain, an empty domain, a given domain, and an explicit apibaseurl.
    • baseline.yml reads the blueprint with no domain.
  • Docs and records:

    • BOOTSTRAP.md: examples, required inputs, troubleshooting row.
    • docs/phases: README, 01-scaffold, and the required-inputs sentence on five pages.
    • saas-lumen-baseline/IMPLEMENTATION-STATUS.md: a dated section, plus a "Since then" note on the superseded "typed inputs" quote.

Verified locally (orun 2.58.11, the CI pin)

check result
manifest, phases, coverage, rebrand all exit 0: 7 milestones, 9 phases, 65 modules, 44/44 components, rebrand 24 checks (15 before)
render-component-docs.py --check exit 0: 44 up to date
orun new --status with no productdomain exit 0
testing/leak.test.sh exit 0: 1083 files derived (unchanged)
testing/placement.test.sh exit 0: 1083 product files (unchanged); DEFAULT_API_URL = https://acme-cloud-api-edge-prod.acme.workers.dev; BASE_DOMAIN ×3 and CONSOLE_CUSTOM_DOMAIN ×2 read acme-cloud.example.com, and 10 files carry it
cloudflare-domain, branded with no domain baseDomain: acme-cloud.example.com, workerNamePrefix: acme-cloud-web-console-next (the console Worker); the same in the TF defaults and README; with brandSlug: acme, acme-web-console-next
mutation: old CLI rule rebrand 3 ✕, placement FAIL; restored, both pass
mutation: no placeholder rebrand 3 ✕, placement FAIL on BASE_DOMAIN ''; restored, both pass
the documented replacement, on a placed product 10 files → 0; BASE_DOMAIN / baseDomain = acme.dev
a second rebrand pass 0 files affected

Generated by Claude Code

- blueprint.yaml: the subdomain input declares
  from: connection.cloudflare.workersSubdomain, with the reason at the field;
  the card already requires [github, cloudflare, supabase]
- testing/manifest.test.sh accepts the source and requires its provider in
  spec.requires.integrations (cirrus-baseline's block, verbatim;
  mutation-checked)
- repo-blueprint.yaml, BOOTSTRAP.md, docs/phases/01-scaffold.md and
  docs/phases/README.md: a console or --from bst_… build never asks for it;
  only a hand-run build passes --set subdomain
- saas-lumen-baseline status: dated record, with a superseded note for the
  console section that called the field typed

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01D8AmgTwmnp4M8mgmnS9aha
…06-console, parked

- repo-blueprint.yaml: the `domain` input, its .rebrand/values.json key and
  the 07-domain phase are gone; cloudflare-domain joins 06-console (it ships
  parked: subscribe.environments: [])
- blueprint.yaml: the programme drops the conditional 07-domain milestone
  (nine phases, seven milestones)
- tasks/07-domain.TaskContract.yaml and docs/phases/07-domain.md deleted;
  what is still true is a section of docs/phases/06-console.md and a row in
  ai/context/operations.md; 06-console's contract says why `affects` leaves
  the parked component out
- tests: phases.test.sh records 07-domain as folded into 06-console;
  leak/placement no longer force `domain` on (1083 files placed, as before);
  the phased sequence places 08-docs after the rebrand
- tests/fixtures/acme.json drops "domain": false
- docs and records: BOOTSTRAP.md, docs/phases/*, a "Since then" note on the
  epic's phase table, and a dated status section

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01D8AmgTwmnp4M8mgmnS9aha
The product answers on workers.dev from its first deploy and nothing in the
build needs a domain, so the console card no longer asks for one. Everything
that uses the domain stays where it is, carrying a placeholder until an owner
sets it. As turso-starter #9.

- blueprint.yaml: no productdomain input, and no apibaseurl (it derived from
  {productdomain}; a card can only derive from inputs it declares)
- repo-blueprint.yaml: productdomain optional, default empty
- rebrand.mjs: productdomain no longer required; empty brands the reserved
  placeholder <reponame>.example.com where sourceplane.ai stood as the
  product domain (intent BASE_DOMAIN/CONSOLE_CUSTOM_DOMAIN, edge and identity
  origins, mail sender, billing success URLs); with no domain the CLI
  default is the prod edge,
  https://<brandSlug>-api-edge-prod.<subdomain>.workers.dev
- cloudflare-domain README examples name sourceplane.ai and
  sourceplane-web-console-next, so they follow the placeholder and the
  console Worker like baseDomain/workerNamePrefix already did (cirrus #32)
- ai/context/operations.md: "Setting the domain later"
- render-deployment-docs.sh: the placeholder is no domain to probe
- tests: fixture carries no domain; placement checks the product's CLI
  default and placeholder instead of the card's derive; rebrand.test.sh
  covers no domain, an empty one and a given one; CI reads the blueprint
  with no domain
- docs: BOOTSTRAP.md, docs/phases; record in saas-lumen-baseline
  (baseline-v4, with #364)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01D8AmgTwmnp4M8mgmnS9aha
@ruehowl
ruehowl marked this pull request as ready for review October 22, 2026 04:04
@ruehowl
ruehowl merged commit 9142484 into main Oct 22, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants