Repository navigation
Description
DR verdict — whole PM-stack backup audit, 2026-11-14
Ordered by Drew 2026-11-14: "Are there any other obvious gaps to our backup routines? Is the rest of the PM stack backed up? If I start up a brand-new computer, could we use backups to get the entire PM stack running?"
Method: read-only audit. Every claim below rests on observed artifacts (files, manifests, journals, R2 listings read back, hashes recomputed), each consequential fact checked with a second independent call. Scratch drills were done only in /tmp on the laptop and cleaned up. Links: design #1258, cutover tracker #3989, DB backup #1514 (closed), slices #6815 / #6816, observability #3869.
Bottom line
No — a brand-new computer could not rebuild the entire PM stack from backups + repos today. The core databases (Kaneo / Grist / Pad) and part of the aggregator state can be rebuilt, and that leg is genuinely good: daily, sha256-manifested, copied to local + R2 + Google Drive with every leg verified, and per-store restore checks pass. But a full rebuild would stall or silently lose pieces at the secrets bootstrap, the SOPS decryption key, the claimant/dispatch state, the decisions ledger, the OpenCode session store, and the laptop-state backup that has not run in 12 days. And the whole-stack rebuild has never been drilled — the runbook is still marked DRAFT — so even the "can" parts are partly inference.
Per-component table (observed 2026-11-14, laptop amd unless noted)
| Component | Backed up? | Where | Cadence | Last success evidence | Restore tested? |
|---|---|---|---|---|---|
| Kaneo Postgres | Yes | pm-stack tar inside dashboard tar → local + R2 (supabase-backups/dashboard/) + Drive (Cloud/cold-store/db-backups/pm-aggregator/) |
Daily ~04:30 | 2026-11-14 archive 19,856,143 B, sha256 d5526abd…; run record .last-run.json all steps ok, R2 + Drive sha-verified in journal |
Yes — 2026-10-27 scratch restore (#1514: 92 TOC / 9,439 rows); 2026-11-14 this audit: pg_restore --list on current dump = 311 TOC entries, 46 TABLE DATA, rc 0 |
| Grist (home.sqlite3, grist-sessions.db, 1 doc) | Yes | Same bundle as Kaneo | Daily | Same 2026-11-14 archive (manifest covers 9 files) | Yes — 2026-10-27 + this audit: PRAGMA integrity_check = ok on home (26 tables), sessions (1), doc (33) from the backup copy |
| Pad (pad.db + encryption.key + config + attachments) | Yes | Same bundle | Daily | Same archive; live attachments dir is empty, so the empty attachments dir in the backup is accurate | Yes — this audit: integrity ok on backup pad.db (87 tables). Full Pad open with key not re-drilled (that was #1514, 2026-10-27) |
| pm-aggregator state (allow-listed files) | Partial | dashboard tar → local + R2 + Drive | Daily | 2026-11-14 tar 22,723,341 B sha256 8d2bd705… (hash recomputed locally, matches record + journal) |
Archive extraction + manifest verify is built into every run; no app-level restore drill |
| pm-aggregator decisions files | No → #10293 | — (decisions.json 3.3 MB, decision-events*.jsonl, board/needs-drew/notifications/digests absent from archive allow-list) |
— | Decision events do sync to Turso every 5 min (verified 11:21, pending=0) — partial mitigation only | No |
| pm-projector DB | By design, mostly no | Only pmp_links SQL export rides the dashboard tar (verified in 2026-11-14 archive, 0 rows) — the rest is a rebuildable projection |
Daily (export) | Archive listing | Rebuild-from-GitHub is inferred, never drilled. Reconcile service is currently healthy (ran ok 11:15 today; the earlier "stuck in activating" was not reproduced — its PR/comment streams do show github_api_403 today, issues stream works) |
| pm-dispatch state | No → #10298 | State dir holds only a witness log; real config is rendered .env files in ~/pm-stack/dispatch/ + ~/secrets/ — neither in a backup set |
— | — | No |
| ready-for-agent | No explicit backup | State = GitHub labels + bare mirror in ~/pm-stack/ready-for-agent/repos/; config in repo |
— | Service running | Rebuild from GitHub inferred |
opencode-claimant state + mode file |
No → #10298 | ~/.local/state/opencode-claimant/ (11 MB) in no backup set; mode file content today: live |
— | — | No |
Fleet queue DB (Supabase muse-dev2, agent schema) |
Yes, but failing → #10296 | Full pg_dump → R2 only (pg/muse-dev2/) |
Twice daily (12h) — target class RPO 15 min, never met by design | R2 manifest read back: newest success 2026-11-13T10:55Z, 44,215,425 B — ~30h stale at audit. Today's 04:49 run failed (pooler SSL drop on agent.events); no watchdog names this job |
Restore recipe documented in ~/tools/supabase-backup/README.md, verified 2026-10-21 for the sibling project export; no recent drill for this project |
| OpenCode server sessions | No → #10297 | ~/.local/share/opencode/opencode.db is 21 GB; nothing covers ~/.local/share/opencode. Same-disk .bak copies are not backups. agent-backup covers only credential files, local-only |
agent-backup: on-change (latest 2026-11-14 09:36, local disk only) | — | No |
OpenCode small state (~/.local/state/opencode) + SOPS files + ~/.ssh |
Stale → #10294 | restic laptop-state repos: local + R2 + Drive |
Designed daily 05:40 | Last snapshot 2026-11-02 17:36 (single snapshot in local repo; success marker 2026-11-02 17:37). Timer has never fired (LastTriggerUSec empty, zero journal entries); watchdog doesn't cover this job |
restic check is part of the job when it runs; no restore drill |
| Secrets — Bitwarden Secrets Manager contents | Cloud-side | Bitwarden cloud (the vault is the off-machine copy); names verified live via fleet secrets list — includes R2, Supabase, Kaneo, Grist, Pad, tunnel, restic passwords, GitHub, Turso keys |
Continuous | List returned ~180 names 2026-11-14 | Bootstrap not recoverable from backups: the BWS access tokens themselves (laptop ~/.config/bws/access-token, sandbox ~/.config/bitwarden/access-token) are in no vault and no backup → #10301 |
| Secrets — SOPS age key (laptop recipient) | No → #10295 | Private key only at ~/.config/sops/age/keys.txt; age-keygen -y proves it is the laptop-framework recipient in the repo .sops.yaml. Only the sandbox age key exists in BWS by name |
— | SOPS ciphertext is backed up — and would be undecryptable after a disk loss | No |
| Secrets — 1Password | Cloud-side | 1Password cloud; service-account tokens themselves live in BWS (names verified) — reachable once BWS is bootstrapped | Continuous | op route verified in standing notes |
Manual Drew login is the root; undocumented in restore docs → #10301 |
| Secrets — rclone Drive OAuth | No → #10301 | Token only in laptop ~/.config/rclone/rclone.conf, in no backup set; every Drive leg depends on it |
— | — | Needs fresh interactive Google sign-in on a new machine |
| Muse-side cron jobs (incl. closure-watchdog) | Yes (sandbox side) | Definitions are Muse-platform records; file copies in ~/workspace/cron.d/ + goal workspaces ride the sandbox home git/restic system |
Continuous / snapshot | Sandbox restic verify log: 1,786 snapshots, latest 2026-11-14T11:11Z | Scheduler itself is platform-provisioned, not backup-restored → #10301 |
| closure-watchdog watermark/state | Yes (sandbox side) | ~/workspace/closure-watchdog/state.json (updated 2026-11-14 17:13) rides the sandbox backup above; script has a catchup-gap self-report if the watermark is lost |
Every 15 min (cron) | State file current today | Catchup path exists by design; loss never drilled |
| Repos themselves | Yes, layered | GitHub (canonical) + laptop github-backup mirrors (2026-11-14 fetch: 826 ok / 0 fail) + restic repo-archive (local+R2+Drive, ran ok today 05:22–06:02) — but the mirrors live on the same laptop disk; offsite repo copy is the restic archive of ~/repo-archive, not the mirror tree |
Daily | Journals + ~/backups/github/MANIFEST.json dated today |
Git clone from GitHub is the de-facto drill, done constantly |
| Atlas DB (adjacent, coordinator's domain) | Partial today | Local + R2 + Drive | Daily | Local 2026-11-14 file exists (470 MB, 04:59) but the service timed out at 90 min (06:28) — offsite legs unproven today; backup-log's last ok laptop/r2/drive entry is 2026-11-13, and the logged sha has been identical since 2026-10-31, which deserves the Atlas owner's look |
Not in this audit's scope |
| Cold-store nightly (D1/Supabase/Turso exports → Drive) | Partial today | Drive | Daily 03:12 | Today: D1 + Supabase legs ok, Turso export leg timed out (service killed at 30 min) | Quarterly drill timer exists (cold-store-drill) |
Brand-new-computer rebuild walk
PROVEN = restore-tested with evidence. INFERRED = should work, never tested end-to-end.
- Hardware / OS — Install NixOS and switch the
amdhost config from thedeveloping-today/codeflake. INFERRED for a new machine (the switch is routine on the current laptop; a cold install + first switch has no drill record). Missing: nothing in data terms — the flake is in git — but the laptop sudo password is a 1Password item (Drew-held root, see step 2). - Secrets bootstrap — INFERRED, with a hard manual gate. Order that works on paper: Drew logs into Bitwarden → mint a new Secrets Manager machine token (the old tokens are in no backup — Backup bootstrap credentials not documented #10301) → fetch by name: restic passwords, R2 backup keys, Supabase DB password, Kaneo/Grist/Pad secrets, tunnel token (
cloudflare.tunnel.amd-6-pm-stack-token— verified present by name) → 1Password service tokens (they live in BWS) → fresh Google OAuth for rclone Drive (token not backed up — Backup bootstrap credentials not documented #10301). Missing piece: the SOPS age private key for the laptop recipient exists nowhere off the laptop — every laptop-recipient SOPS file is undecryptable on the new machine (SOPS decryption key not recoverable #10295). - Repos — Clone the four repos from GitHub; alternatively restore laptop mirrors. PROVEN in effect (clones happen daily across worktrees; github-backup mirrors verified today).
- Services —
nixos-rebuild switchbrings up the systemd units + Docker stacks from the flake. INFERRED as a cold path: the deployed tree~/pm-stack/is not a git repo and its rendered files (tunnel.token,tunnel.env,dispatch/.env) must be re-rendered from vault/SOPS — possible for the tunnel (vault name exists), unverified file-by-file for the rest (Claimant dispatch state not backed #10298). pm-git-sync was observed failed today on a dirty primary checkout (another lane's files) — on a clean new machine that specific failure vanishes, but it shows the deploy path assumes a clean checkout. - Data restores —
- Kaneo:
pg_restorethe daily dump. PROVEN at TOC level (2026-10-27 full scratch restore; 2026-11-14 TOC parse). RPO gap: daily dump vs the accepted 1h target. - Grist: copy back home/sessions/docs from the bundle. PROVEN at integrity level (today, from the actual backup copy).
- Pad: copy back pad.db +
encryption.key(it rides the same bundle — good) + config. PROVEN at integrity level; app-open with key last proven 2026-10-27. - Aggregator: unpack the dashboard tar's allow-listed files. PARTIAL —
decisions.jsonand friends aren't in the archive (Decisions ledger missing from backups #10293); decision events could be replayed from Turso (inferred). - Projector: start empty, reconcile from GitHub;
pmp_linksfrom the export. INFERRED. - Fleet queue: the queue itself lives in Supabase cloud — a new laptop doesn't need its restore at all; restoring Supabase from the R2 dump is documented but the dump is currently ~30h stale and the job is failing (Fleet queue backup failing silently #10296).
- OpenCode sessions: cannot be restored — no copy exists (OpenCode session database lacks backup #10297). Claimant mode: recreate by hand, content today is
live(Claimant dispatch state not backed #10298). Laptop state (SSH keys, SOPS files): restic restore works from a 2026-11-02 snapshot (Laptop state backup stopped running #10294).
- Kaneo:
- Offsite copies — Pull from R2 (works once BWS is bootstrapped) or Drive (works once rclone is re-authed). The dashboard bundle's R2 + Drive legs were sha-verified in today's run record — PROVEN that today's generation is really off-machine.
- Public entry — Re-point / re-run the Cloudflare tunnel with the vault-held token; Access policy is Cloudflare-side. INFERRED (never moved in a drill).
- Verification / smoke — Runbook smoke steps exist (
pm-stack/COLD-RESTORE-RUNBOOK.md) but the runbook is DRAFT,doc/pm-stack/restore-drills/does not exist, and no full-stack drill has ever been recorded (Full stack restore never drilled #10300). INFERRED.
The 7 design questions from #1258 — status, with recommendations
Correction to the audit brief: these are not still awaiting Drew. The #1258 comment thread records Drew ruling on all seven on 2026-11-03 (posted through 2026-11-05): Q2/Q7 all-in-Supabase; Q1/Q4/Q5 accepted as proposed; Q3/Q6 retention decided — and #3989's triage recorded the cutover as ungated. They are surfaced here as instructed, each with the ruling, my recommendation, and the conformance gap this audit found:
- RTO/RPO targets (4h core RTO; 15m aggregator; 1h Kaneo/usage/link; 24h Grist/Pad/Project). Ruling: accepted. My recommendation: keep them — and publish actuals against them. Conformance: Grist/Pad meet theirs; Kaneo's daily dump gives ~24h RPO vs the 1h target, and the aggregator JSON stores give ~24h vs 15m. Those two misses are the sharpest numbers in this audit.
- Canonical DB homes. Ruling: superseded — ALL PM-stack state to Supabase
muse-dev2; no cluster Postgres/volumes as system of record; no laptop-local exceptions (Q7). My recommendation: keep the ruling; judge impl(pm-stack): move the aggregator laptop-local JSON stores to Supabase muse-dev2 (#3989 slice) #6815/impl(pm-stack): Kaneo/Grist/Pad canonical stores to Supabase-backed homes + cold-restore runbook and first laptop-off drill (#3989 slice) #6816 against it literally — including an explicit mapping for file-shaped stores (Grist docs, Pad attachments) rather than silent exceptions, exactly as Drew's ruling itself instructed. - Backup destinations + retention (local + R2 + Drive; daily 30d + monthly 12mo off-machine). Ruling: decided, as stated. My recommendation: keep — and implement the monthly tier, which does not exist anywhere today (Monthly backup generations not kept #10299).
- Failover posture. Ruling: tested cold restore ≤4h, no warm standby; GitHub is the degraded mode. My recommendation: keep. Conformance: the "tested" half is unmet — no drill yet (Full stack restore never drilled #10300).
- Restore evidence (
doc/pm-stack/restore-drills/YYYY-MM.md; monthly rotating / quarterly full / annual laptop-off). Ruling: approved. My recommendation: keep — start the rotation this month; the directory doesn't exist and the first monthly restore is already overdue under the ruling. - Project export retention (pm-stack: make Project #4 auditable — scheduled export of fields, views, item counts, status/area distribution #1218 exports kept off-machine 1 year). Ruling: 1 year. My recommendation: keep. Conformance: pm-stack: make Project #4 auditable — scheduled export of fields, views, item counts, status/area distribution #1218 is closed but no off-machine export copy with that retention was found (Monthly backup generations not kept #10299).
- Laptop-local exceptions. Ruling: none — nothing intentionally laptop-only. My recommendation: keep, and treat every "No" row in the table above as a ruling violation to close, not a preference: decisions ledger (Decisions ledger missing from backups #10293), claimant/dispatch state (Claimant dispatch state not backed #10298), OpenCode sessions (OpenCode session database lacks backup #10297), SOPS age key (SOPS decryption key not recoverable #10295) are all unique laptop-only records today.
Gap issues filed by this audit
#10293 decisions ledger · #10294 laptop-state stall · #10295 SOPS age key · #10296 fleet-queue backup failing · #10297 OpenCode session DB · #10298 claimant/dispatch state · #10299 monthly retention · #10300 full-stack drill · #10301 bootstrap credentials
Also observed, left to their existing owners (not re-filed): atlas-backup timeout + unchanged atlas sha since 2026-10-31 (Atlas track); cold-store Turso leg timeout today (#1723 track); pm-git-sync failing on a dirty checkout (fleet hygiene track); supabase-backup's watchdog absence is folded into #10296.
Activity
developing-today commentedon Nov 14, 2026
CODE-3712
dezren39 commentedon Nov 17, 2026
Triage verdict (task 19226, lane any-d): this issue is the 2026-11-14 whole-stack backup / disaster-recovery audit record for pm-stack. Fresh check this shift: issue #10304 is OPEN, no labels, no hard-stop labels; the audit itself is complete as a work product — its actionable content was already split by the audit into nine scoped gap issues, all verified OPEN this shift: #10293 (decisions ledger not in dashboard archive), #10294 (laptop-state restic stall), #10295 (SOPS age key laptop-only), #10296 (fleet-queue Supabase backup failing/stale), #10297 (OpenCode session DB unbacked), #10298 (claimant/dispatch state laptop-only), #10299 (monthly retention tier missing), #10300 (no full-stack restore drill), #10301 (bootstrap credentials unrecoverable). Each gap issue carries its own bulk-intake queue task, so no new follow-on packet is enqueued from this triage (dedupe: the follow-ons already exist as issues + tasks).
Work kind: task/triage (audit record; fixes live in the gap issues). Priority: priority/normal — infrastructure resilience under priorities-brief line 4 (PM stack / infra), not a fleet-stalling band-10 item; the sharpest sub-items (#10296 queue backup, #10295 SOPS key) get their own triage bands on their own tasks. Effort: effort/xs for this record. Kind: kind/infrastructure. Acceptance check for the parent: every gap issue reaches its own triaged/fixed terminal state; the parent closes when the gap set closes or Drew accepts the residual risk. First concrete step: none on this issue itself — work proceeds on #10293-#10301.
dezren39 commentedon Nov 18, 2026
Triage — queue task 20564, openchamber scheduled lane (oc-code-03), 2026-11-18.
Fresh GitHub state (08:52 UTC): #10304 OPEN, labels status/triaged, kind/infrastructure, no native blockers.
Verdict: triaged, audit record. This issue is the 2026-11-14 DR audit verdict; its actionable items are the separate laptop backup and SOPS-key issues (#10295, #10296), both already triaged. No code change and no follow-on packet is enqueued here.