Document backup, restore and upgrade procedures (closes #210) #214

Merged
clawbot merged 1 commits from issue-210-backup-restore-upgrade-docs into next 2026-08-20 06:05:15 +02:00

1 Commits

Author SHA1 Message Date
clawbot
0f2ac5a3c8 Document backup, restore and upgrade procedures (closes #210)
All checks were successful
check / check (push) Successful in 10s
The README had nothing on any of the three, leaving an operator with
no answer to which files to back up, whether a hot copy is safe, how
to restore, or what a newer image does to their data.

Adds a "Backup, Restore, and Upgrades" section covering:

- the backup set: webhooker.db, one events-{uuid}.db per webhook, one
  archive-{uuid}.db per webhook with a database target, all under
  DATA_DIR, plus the .env that is not under it
- why a hot copy is unsafe (no journal_mode pragma is issued on any
  DSN, so every database runs the default rollback journal, and the
  main and event handles stay open for the process lifetime), with
  stop-copy-start and sqlite3 .backup as the safe procedures
- restore: the whole set together, since a missing events DB is
  created empty rather than erroring, and chown to UID 1000 because
  SQLite needs to write the journal beside the database
- upgrade: AutoMigrate runs unconditionally on every start against
  all three database kinds, there is no schema version table and no
  down migrations, so back up first and downgrade is unsupported
- that event and archive databases hold full payload bodies and
  headers, that event databases also carry target credentials until
  #206 is fixed, and that target config in webhooker.db is
  unencrypted, tracked in #212

Docs only; no code, config, script or build changes.
2026-08-20 04:01:53 +00:00