Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS
JavaScript ai-agentsdashboarddeveloper-toolsdigital-twinquantified-selfsecond-brainself-hostedtailscale
docs: state that maintenance recovery receipts are never restored
Claudeee475c04ec5a
diff --git a/docs/BACKUP.md b/docs/BACKUP.mdindex 904c6d6b9e..3f70aedb3b 100644--- a/docs/BACKUP.md+++ b/docs/BACKUP.md@@ -499,7 +499,7 @@ After the preflight, rsync copies `<snapshot>/data/` back to `./data/`. Restore#### Database authority is not restored-`data/database-authority.json` is backed up as cutover evidence but is never installed by a file restore. It records which database backend a completed cutover retired on the machine that ran it, so restoring it from another machine's snapshot (or from an older snapshot after a reverse cutover) would make PortOS refuse its own healthy database with `DATABASE_RETIRED_BACKEND`, including after a restart. Every file restore therefore excludes it, in preview and execution alike, and the integrity preflight ignores it too. The destination's existing file stays byte-for-byte as it was: an absent record stays absent and a damaged one stays fail-closed. Other records in the snapshot restore normally. Selecting `database-authority.json` itself is refused with `BACKUP_RESTORE_MACHINE_LOCAL` before anything is transferred. This does not touch an active maintenance journal (`database-maintenance/`): its recovery semantics are unchanged, and another machine's cutover endpoints are never imported. To change which backend is authoritative, run a database cutover.+`data/database-authority.json` is backed up as cutover evidence but is never installed by a file restore. It records which database backend a completed cutover retired on the machine that ran it, so restoring it from another machine's snapshot (or from an older snapshot after a reverse cutover) would make PortOS refuse its own healthy database with `DATABASE_RETIRED_BACKEND`, including after a restart. Every file restore therefore excludes it, in preview and execution alike, and the integrity preflight ignores it too. The destination's existing file stays byte-for-byte as it was: an absent record stays absent and a damaged one stays fail-closed. The same preservation covers the other machine-local authority and recovery records — `peer-execution/`, `peer-execution-*.json`, `peer-execution-recovery.jsonl`, `workflow-maintenance/` (the graceful-maintenance journal and abandoned-run receipts) and `backup-admission/` (which snapshots also skip) — so a snapshot's copy is evidence only (see [STORAGE.md](./STORAGE.md)). Other records in the snapshot restore normally. Selecting any of these paths, including `database-authority.json` itself, is refused with `BACKUP_RESTORE_MACHINE_LOCAL` before anything is transferred. This does not touch an active maintenance journal (`database-maintenance/`): its recovery semantics are unchanged, and another machine's cutover endpoints are never imported. To change which backend is authoritative, run a database cutover.### Database — `restorePostgres()`diff --git a/docs/STORAGE.md b/docs/STORAGE.mdindex cade412928..4f0b494545 100644--- a/docs/STORAGE.md+++ b/docs/STORAGE.md@@ -9,7 +9,9 @@ PostgreSQL is a **required** install/runtime dependency (see [Backup & Restore](Graceful maintenance uses `data/workflow-maintenance/state.json` as a **file-primary,machine-local runtime journal**. It must fence both the API and standalone CoS runnerbefore either can use PostgreSQL or start work. Its bounded live-operation set and-operator hold are not app records, never federate, and are included in the data backup.+operator hold are not app records and never federate. Data snapshots copy the+`workflow-maintenance/` subtree as evidence, but no restore ever installs it (see+[Explicitly abandoned duplicate agents](#explicitly-abandoned-duplicate-agents)).The schema is versioned; an absent file starts Normal, while corrupt/future state oran interrupted transaction fails closed. Replacement uses exclusive directory locking,file/directory fsync and atomic rename. No seed or DB migration is required.@@ -74,9 +76,14 @@ operator reason, and evidence fingerprints. Other operations and the hold remainRun/task outcomes are unchanged. Repeating the same request reuses its receipt;it cannot settle a replacement reservation. Receipt-first interrupted publicationcan be retried after normal journal recovery; the command never steals a transaction-lock. These machine-local recovery receipts are included in the data backup and-never federated. This deliberately narrow command does not recover nonempty output-or general failed saves; those still require the owning workflow's recovery.+lock. These machine-local recovery receipts are never federated and never restored:+a data snapshot copies them, but every file restore (full or scoped, preview and+execution) preserves this machine's `workflow-maintenance/` subtree byte-for-byte+and refuses an explicit selection with `BACKUP_RESTORE_MACHINE_LOCAL`, because+installing another snapshot's journal or receipts would replace local authority.+To use a receipt as an investigation artifact elsewhere, copy it out of the+snapshot or the live data directory separately. This deliberately narrow command+does not recover nonempty output or general failed saves; those still require the owning workflow's recovery.## The Four Storage Classes