Skip to content

Feat(ops): age-encrypted Postgres backups - #6

Merged
DigitalJacob merged 8 commits into
mainfrom
feat/encrypted-postgres-backups
Nov 22, 2026
Merged

DigitalJacob merged 8 commits into
mainfrom
feat/encrypted-postgres-backups

Conversation

@DigitalJacob

@DigitalJacob DigitalJacob commented Nov 14, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Age-encrypted Postgres backup / restore / prune via Compose (pg_dump piped into age, atomic *.partial → final file)
  • Safe dotenv loading (scripts/_lib.sh); dumps and keys stay gitignored
  • README Backups runbook + optional systemd timer units under deploy/

Test plan

  • age-keygen, set BACKUP_AGE_RECIPIENT (and identity path for restore) in .env
  • ./scripts/backup_postgres.sh → only backups/*.dump.age (no plaintext / no .partial left)
  • CONFIRM_RESTORE=1 ./scripts/restore_postgres.sh … into ${POSTGRES_DB}_restore
  • With BACKUP_KEEP_DAYS, confirm prune after backup
  • CLI override: BACKUP_KEEP_DAYS=1 ./scripts/prune_backups.sh wins over .env
  • (optional) install timer units with edited paths; systemctl list-timers

@DigitalJacob
DigitalJacob merged commit 62b8031 into main Nov 22, 2026
1 check passed
@DigitalJacob
DigitalJacob deleted the feat/encrypted-postgres-backups branch November 22, 2026 10:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant