I found restic-compose-backup while looking for a simple solution to back up the volumes in my compose stacks. Unfortunately, the project was abandoned, and some things have broken over time. I have forked the project, returned it to a working state, and added some enhancements.
Huge thank you to Zetta.IO for making such an awesome tool!
Updates and Fixes
- Updated pip commands in Dockerfile because current Alpine python3 version no longer allows pip system installs
- Updated Postgres client from the Alpine edge repo because the current Alpine Postgres client package doesn't support Postgres 17
- Updated docker Python package used in
rcb
because original version now throws an error due to deprecated protocol handler when interacting with the docker socket - Updated restic base image version to the current release
Enhancements
- Added
--single-transaction
flag tomysqldump
to prevent inconsistent backups for live databases - MariaDB environment variables updated to
MARIADB_USER
andMARIADB_PASSWORD
fromMYSQL_*
to match the supported variables for the official mariadb container image - If
MYSQL_ROOT_PASSWORD
orMARIADB_ROOT_PASSWORD
are available, use that for backup instead of the regular user account. - Created image build and publish workflow to automatically publish the container image on ghcr.io on updates to
master
or tag push / release. .env
template file changed to.env.template
and added.env
to.gitignore
to prevent accidental commits- Updated README to make examples clear and concise
- Automated tests and release workflow with GitHub Actions