feat: add restore drill coverage
Quality / test (push) Canceled after 0s

Add restore verification and image-storage recovery scripts, update deployment documentation, and note the restore drill milestone in the implementation status.
This commit is contained in:
2026-09-09 22:35:25 -04:00
parent 76e40d7289
commit 79df9d5c88
5 changed files with 102 additions and 5 deletions
+20 -2
View File
@@ -132,12 +132,30 @@ BACKUP_FILE=/secure/backups/inventory-20260909T000000Z.dump \
This checks that the file is a readable PostgreSQL custom-format archive without
changing any database.
Restore a database dump during a scheduled window:
```sh
BACKUP_FILE=/secure/backups/inventory-20260909T000000Z.dump \
POSTGRES_DB=inventory \
POSTGRES_USER=inventory \
POSTGRES_PASSWORD='use-secret-storage' \
./scripts/restore-postgres.sh
```
Restore image storage snapshots using the preserved NAS backup:
```sh
IMAGE_STORAGE_SOURCE=/secure/backups/pokemon-inventory-images \
IMAGE_STORAGE_DESTINATION=/var/lib/pokemon-inventory/images \
./scripts/restore-image-storage.sh
```
Back up image storage and the deployment `.env` through the NAS secret/backup
system as well. Never commit either one. Before upgrading, record the current
image tags and database migration state. To roll back, stop the application
services, restore the previous image tags, restore the database dump if the
schema changed, then start the stack and verify `/health` and a read-only
catalog request.
schema changed, then restore the image snapshot and verify `/health` and a
read-only catalog request.
## Reverse proxy