Skip to content

feat: backup script#876

Open
gegabega wants to merge 3 commits into
invoiceninja:debianfrom
gegabega:feat/backup-script
Open

feat: backup script#876
gegabega wants to merge 3 commits into
invoiceninja:debianfrom
gegabega:feat/backup-script

Conversation

@gegabega

@gegabega gegabega commented Apr 8, 2026

Copy link
Copy Markdown

Summary

  • Automatic daily/weekly/monthly backups via cron inside the app container
  • Backs up MySQL (mysqldump) + storage volume into timestamped .tar.gz archives (format YYYY-MM-DD-.tar.gz)
  • Tiered retention: daily 7d, weekly 30d, monthly 120d (took inspiration from your old master branch here)
  • Uses basename/symlink pattern (also similar to your old master)

Changes

  • debian/scripts/backup.sh – backup script with frequency detection via basename
  • debian/Dockerfile – add cron, copy script, symlink to cron.daily/weekly/monthly
  • debian/supervisor/supervisord.conf – add [program:cron]
  • debian/docker-compose.yml – add app_backups volume
  • debian/scripts/init.sh – ensure /backups dir on startup
  • README.md – backup/restore docs, checked off todo
  • debian/scripts/test_backup.sh – shell unit test (can be removed if unwanted ofc)

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