Apply Luna copy pass to the demo follow-up strings
Flag help for the starter, the superseded status message and the README issuer sentence, as the delegated Luna pass returned them (no flags). Deck delta recorded in copy-agent-start-demo-1.md.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
README.md+1 −1docs/superpowers/notes/copy-agent-start-demo-1.md+16 −0docs/superpowers/specs/LUNA-COPY-BRIEF-AGENT-START-DEMO-1-FOLLOWUPS.md+23 −0internal/console/apidemo.go+1 −1internal/console/demo_followups_test.go+1 −1internal/console/testdata/demo/main.go+2 −2
CI passed — run details
Intent
<task-notification> <task-id>bk6u21f7d</task-id> <tool-use-id>toolu_015ipfgktBdztKidqAieBdze</tool-use-id> <output-file>/home/paulca/.cache/tmp/claude-1001/-home-paulca-amadan-net-carlos-platform/bb61bb66-e14e-4d6f-a575-56f0b61402d9/tasks/bk6u21f7d.output</output-file> <status>completed</status> <summary>Background command "Wait for Luna result" completed (exit code 0)</summary> </task-notification>
Attributed to this commit: 84.7 g CO₂e (2,394,953 tokens). This is an attribution, not a measurement — usage counted from this commit's own marker forward to the next one on agent-start-demo-1-followups, never backward from it. A turn that produced more than one commit books all of its tokens to the last one, and a concurrent session on this branch can add to the same figure. Some of it was priced using the shared default rate, because no model-specific factor row exists yet for at least one model involved. The Carbon view has the repo total, which is never derived from this attribution.
diff --git a/README.md b/README.md| index ae16dcc03..2323ea92d 100644 |
| --- a/README.md |
| +++ b/README.md |
| @@ -631,7 +631,7 @@ Build the toolchain bundle on the operator side before enabling a worker. Use na |
| Make the directory and its ancestors root-owned and safe from agent writes. Bundle files must be regular files with mode `0444` or `0555`; symlinks, hard links and unlisted files are refused. Write `MANIFEST` with LF endings and a final LF. Its first lines are `go<TAB>1.26.10` and `modules<TAB><Lock.ModulesDigest()>`. Follow them with one tab-separated row per file other than `MANIFEST`, sorted by relative path: relative path, four-digit octal mode, decimal size, lowercase SHA-256. `Lock.ModulesDigest()` hashes the canonical dependency lock; the worker's bundle digest separately hashes the exact manifest bytes. `host.CheckDemoToolchain` checks the entire bundle, then worker initialization must pass the nested isolation check and compile its trusted probe in the disposable offline service. There is no download fallback. To replace a bundle, drain builds, install a new immutable directory, update the per-box path and restart root control. |
| -On every ingress box that fronts the demo domain and every box that can become the housekeeper, set the same `CARLOS_DEMO_ACCOUNT`, `CARLOS_DEMO_FLEET` and `CARLOS_DEMO_DOMAIN` in root-owned `/etc/carlos/host.env`, without `CARLOS_DEMO_BOX`. Preserve these per-box values through host.env rewrites. The housekeeper is the deployment's certificate issuer and orders the demo wildcard. Give every box that can hold that role the DNS-01 grant on the demo zone, even if it does not serve ingress traffic. The edge reads these settings at startup, so restart `carlos-edge` on each affected box as part of the rollout after changing them. |
| +On every ingress box for the demo domain and every box that can become the housekeeper, set the same `CARLOS_DEMO_ACCOUNT`, `CARLOS_DEMO_FLEET` and `CARLOS_DEMO_DOMAIN` in root-owned `/etc/carlos/host.env`, without `CARLOS_DEMO_BOX`. Preserve these per-box values through host.env rewrites. The housekeeper is the deployment's certificate issuer and orders the demo wildcard. Give every box that can hold that role the DNS-01 grant on the demo zone, even if it does not serve ingress traffic. The edge reads these settings at startup, so restart `carlos-edge` on each affected box as part of the rollout after changing them. |
| For an approved rollout, point wildcard DNS for your demo domain at the existing ingress and install wildcard TLS through the deployment's existing certificate workflow. The edge includes `CARLOS_DEMO_DOMAIN` among its explicit wildcard parents. Roll out the built boxes and ingress first, then the console. Confirm the box reports `anonymous-demo-v1` with the expected verified bundle digest, the policy writer can acquire its lease, and change delivery is working before enabling admission. Verify an ordinary app through its own hostname as well. |
diff --git a/docs/superpowers/notes/copy-agent-start-demo-1.md b/docs/superpowers/notes/copy-agent-start-demo-1.md| index 0ac3841da..44c19bb14 100644 |
| --- a/docs/superpowers/notes/copy-agent-start-demo-1.md |
| +++ b/docs/superpowers/notes/copy-agent-start-demo-1.md |
| @@ -155,3 +155,19 @@ Approved by the same delegation: Luna copy pass (gpt-5.6-luna), 2026-11-03, cont |
| | DEMO-EXPIRED-CLEANUP-LOG | operator log | console: DEMO-EXPIRED: %s demo=%s host=%s box=%s: %v | copy message, demo ID, host, assigned box, error | internal/console/demo_expiry.go:expireDemos | |
| | DEMO-EXPIRED-WAITING-LOG | operator log | console: DEMO-EXPIRED: %s demo=%s host=%s box=%s | copy message, demo ID, host, assigned box | internal/console/demo_expiry.go:expireDemoLocked | |
| | DEMO-EXPIRED | audit | This demo has expired and will be removed permanently. | none | internal/console/demo_expiry.go:expireDemoLocked; internal/console/apidemo.go:demoCopy | |
| + |
| +## Follow-ups delta (approved by delegation) |
| + |
| +Approved by the same delegation: Luna copy pass (gpt-5.6-luna), 2026-11-04, controller ruling R22. Brief: `docs/superpowers/specs/LUNA-COPY-BRIEF-AGENT-START-DEMO-1-FOLLOWUPS.md`. No flags. Branch `agent-start-demo-1-followups` (amadan #527). |
| + |
| +| key | kind | current text | placeholders | where | |
| +| --- | --- | --- | --- | --- | |
| +| STARTER-SOCKET | starter flag help | path to the Unix socket | none | internal/console/testdata/demo/main.go:16 | |
| +| STARTER-DB | starter flag help | path to the SQLite database | none | internal/console/testdata/demo/main.go:17 | |
| +| DEMO-BUILD | API refusal relayed to a person | Demo builds are unavailable right now. Try again shortly. | none | internal/console/apidemo.go:42 | |
| +| DEMO-SUPERSEDED | API status relayed to a person | A newer update replaced this job. Follow the newer update's status URL. | none | internal/console/apidemo.go:45 | |
| +| README-ISSUER-TUPLE | operator docs | On every ingress box for the demo domain and every box that can become the housekeeper, set the same `CARLOS_DEMO_ACCOUNT`, `CARLOS_DEMO_FLEET` and `CARLOS_DEMO_DOMAIN` in root-owned `/etc/carlos/host.env`, without `CARLOS_DEMO_BOX`. | none | README.md:634 | |
| +| README-ISSUER-DNS | operator docs | unchanged from draft (see README.md:634) | none | README.md:634 | |
| +| README-ISSUER-RESTART | operator docs | unchanged from draft (see README.md:634) | none | README.md:634 | |
| +| README-STATUS | operator docs | unchanged from draft (see README.md:638) | none | README.md:638 | |
| +| README-RETRY | operator docs | unchanged from draft (see README.md:638) | none | README.md:638 | |
diff --git a/docs/superpowers/specs/LUNA-COPY-BRIEF-AGENT-START-DEMO-1-FOLLOWUPS.md b/docs/superpowers/specs/LUNA-COPY-BRIEF-AGENT-START-DEMO-1-FOLLOWUPS.md| new file mode 100644 |
| index 000000000..d581fff90 |
| --- /dev/null |
| +++ b/docs/superpowers/specs/LUNA-COPY-BRIEF-AGENT-START-DEMO-1-FOLLOWUPS.md |
| @@ -0,0 +1,23 @@ |
| +# Copy pass brief: anonymous demo follow-ups (delta) |
| + |
| +Follow `docs/superpowers/specs/LUNA-COPY-BRIEF-AGENT-START-DEMO-1.md` in this repo exactly: the feature, the three audiences, the house rules, the facts that must stay true and the output format all apply. Read it first. The approved deck is `docs/superpowers/notes/copy-agent-start-demo-1.md`; match its voice. |
| + |
| +This is a delta: only the strings below were added or changed on branch `agent-start-demo-1-followups`. Context for the new facts: |
| + |
| +- An update makes a new job. The earlier job's status now reads `superseded` (it used to read failed). The agent should follow the newer job's status URL. |
| +- Right after a console restart, build workers take a few seconds to reconnect. Create and update refuse with 503 and `Retry-After: 15`. That refusal does not use up a create or update attempt. |
| +- The wildcard TLS certificate for the demo domain is ordered by whichever box is the housekeeper (the deployment's certificate issuer), so every box that can become housekeeper needs the demo settings and DNS permission, not just ingress boxes. |
| + |
| +| key | kind | current text | placeholders | where | |
| +| --- | --- | --- | --- | --- | |
| +| STARTER-SOCKET | flag help shown to a developer reading the starter | Unix socket path | none | internal/console/testdata/demo/main.go:16 | |
| +| STARTER-DB | flag help shown to a developer reading the starter | SQLite database path | none | internal/console/testdata/demo/main.go:17 | |
| +| DEMO-BUILD | API refusal relayed to a person (replaces "Demo builds are unavailable right now. Try again later.") | Demo builds are unavailable right now. Try again shortly. | none | internal/console/apidemo.go:42 | |
| +| DEMO-SUPERSEDED | API status relayed to a person | A newer update replaced this job. | none | internal/console/apidemo.go:45 | |
| +| README-ISSUER-TUPLE | operator docs | On every ingress box that fronts the demo domain and every box that can become the housekeeper, set the same `CARLOS_DEMO_ACCOUNT`, `CARLOS_DEMO_FLEET` and `CARLOS_DEMO_DOMAIN` in root-owned `/etc/carlos/host.env`, without `CARLOS_DEMO_BOX`. | none | README.md:634 | |
| +| README-ISSUER-DNS | operator docs | The housekeeper is the deployment's certificate issuer and orders the demo wildcard. Give every box that can hold that role the DNS-01 grant on the demo zone, even if it does not serve ingress traffic. | none | README.md:634 | |
| +| README-ISSUER-RESTART | operator docs | The edge reads these settings at startup, so restart `carlos-edge` on each affected box as part of the rollout after changing them. | none | README.md:634 | |
| +| README-STATUS | operator docs | The other states are `building`, `starting`, `failed` and `superseded`. An earlier job becomes `superseded` when a newer update is accepted, even if the earlier job was live. Use the new update's `statusUrl` to follow its progress. | none | README.md:638 | |
| +| README-RETRY | operator docs | If a worker has not reconnected after a console restart, create and update return `503` with `Retry-After: 15`. Retry after that many seconds; this refusal does not spend a create or update attempt. | none | README.md:638 | |
| + |
| +Answer with the table and Flags as the main brief says. Do not edit any file. |
diff --git a/internal/console/apidemo.go b/internal/console/apidemo.go| index 9eca3401b..6a3b53583 100644 |
| --- a/internal/console/apidemo.go |
| +++ b/internal/console/apidemo.go |
| @@ -42,7 +42,7 @@ var demoCopy = map[string]string{ |
| "DEMO-BUILD": "Demo builds are unavailable right now. Try again shortly.", |
| "DEMO-BUILD-STARTING": "The demo is starting.", |
| "DEMO-BUILD-FINISHING": "The update is finishing. Try again shortly.", |
| - "DEMO-SUPERSEDED": "A newer update replaced this job.", |
| + "DEMO-SUPERSEDED": "A newer update replaced this job. Follow the newer update's status URL.", |
| "DEMO-BUILD-LIVE": "The demo is live.", |
| "DEMO-BUILD-FAILED": "The demo could not start. Send another update with the same token.", |
| "DEMO-ROLLED-BACK": "The update failed, but the previous version is still running. Send another update with the same token.", |
diff --git a/internal/console/demo_followups_test.go b/internal/console/demo_followups_test.go| index 04ca25d81..4c4e782b1 100644 |
| --- a/internal/console/demo_followups_test.go |
| +++ b/internal/console/demo_followups_test.go |
| @@ -42,7 +42,7 @@ func TestDemoSupersededJobStatus(t *testing.T) { |
| t.Fatal(err) |
| } |
| got := demoSettlementStatus(t, s, j) |
| - if got["state"] != "superseded" || got["message"] != "A newer update replaced this job." || got["url"] != nil { |
| + if got["state"] != "superseded" || got["message"] != "A newer update replaced this job. Follow the newer update's status URL." || got["url"] != nil { |
| t.Fatalf("previous %s, next %s: %v", original, nextState, got) |
| } |
| } |
diff --git a/internal/console/testdata/demo/main.go b/internal/console/testdata/demo/main.go| index 406c03511..ea6addf0c 100644 |
| --- a/internal/console/testdata/demo/main.go |
| +++ b/internal/console/testdata/demo/main.go |
| @@ -13,8 +13,8 @@ import ( |
| const revision = "one" |
| func main() { |
| - socket := flag.String("socket", "", "Unix socket path") |
| - database := flag.String("db", "", "SQLite database path") |
| + socket := flag.String("socket", "", "path to the Unix socket") |
| + database := flag.String("db", "", "path to the SQLite database") |
| flag.Parse() |
| db, err := rastrillo.OpenDB(*database, []string{`CREATE TABLE IF NOT EXISTS state (id INTEGER PRIMARY KEY, value TEXT NOT NULL)`}) |
| if err != nil { |