Commit Graph
4 Commits
Author SHA1 Message Date
overseerandClaude Opus 5.5 442339f887 Contain the Litestream sidecar's write access to the database volume
Review finding F-01: the litestream service mounts nestquest-db
read-write. A read-only mount is not possible: Litestream 0.5.17 fails
with "unable to open database file (14)" on a :ro mount, even with
meta-path moved to a separate writable volume, because it writes its
_litestream_seq/_litestream_lock tables into the database, opens the
-wal/-shm files for writing and checkpoints the WAL.

Keep the write mount and contain it instead: run as the API's non-root
volume owner (999:999) with a read-only root filesystem (tmpfs /tmp),
no-new-privileges and all capabilities dropped. Document why in
compose and api/README.md, including the key chown the uid change needs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-24 08:28:57 -04:00
overseerandClaude Opus 5.5 89a10edc38 Add Litestream continuous backup of the SQLite database
Task 47b27ccb: a litestream sidecar (litestream/litestream:0.5.17) in
deploy/compose.yaml mounts the nestquest-db volume and replicates
/var/lib/nestquest/nestquest.db over SFTP to the Synology NAS
(10.60.1.50, /homes/Joshua/nestquest-backups), outside the Docker host.
deploy/litestream.yml holds no secrets: the NAS host key is pinned and
the dedicated SFTP private key is mounted read-only from the
git-ignored deploy/litestream_key. api/README.md documents what runs,
where it writes, key setup, and a high-level restore.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-24 08:15:53 -04:00
dev_agent f6d222764c Task 9d121e76: Reverse proxy and TLS for the API (#214) 2026-09-24 08:00:04 -04:00
dev_agent 9b068926a9 Containerize the API with a persistent volume (#183) 2026-09-23 12:41:44 -04:00