Files
docker-compose-backup/config.example.yaml
T
2026-07-04 17:20:28 +08:00

35 lines
1.1 KiB
YAML

# docker-compose-backup example configuration
global:
backup_dir: /opt/docker-compose-backup/backups
# temp_dir: /tmp/docker-compose-backup # defaults to OS temp dir
projects:
- name: myapp
path: /opt/docker/myapp
compose_file: docker-compose.yml # default
cron: "0 3 * * *" # daily at 3 AM, standard 5-field cron
exclude:
- ".git"
- "node_modules"
retention:
count: 7 # keep last 7 backups
# days: 30 # optional: also delete older than N days
- name: blog
path: /opt/docker/blog
cron: "0 */6 * * *" # every 6 hours
# Remote upload (optional) — uncomment and configure as needed.
# remote:
# s3:
# endpoint: https://s3.example.com
# bucket: my-backups
# access_key: ${S3_ACCESS_KEY}
# secret_key: ${S3_SECRET_KEY}
# region: us-east-1
# path_prefix: docker-backups/
#
# webdav:
# url: https://webdav.example.com/backups
# username: backup-user
# password: ${WEBDAV_PASSWORD}