adjust one borgmatic config

This commit is contained in:
2025-09-01 09:20:16 +02:00
parent 06cc7755d8
commit 7ab7c0bd7c
2 changed files with 24 additions and 35 deletions

View File

@@ -5,37 +5,26 @@ location:
- '- /shuttle/home/.snapshot' - '- /shuttle/home/.snapshot'
- '- /shuttle/home/*/.cache' - '- /shuttle/home/*/.cache'
repositories: repositories:
- /repo/home - path: /repo/home
storage:
compression: lz4
archive_name_format: '{now:%Y-%m-%d}'
unknown_unencrypted_repo_access_is_ok: true
retention: compression: lz4
keep_daily: 7 archive_name_format: '{now:%Y-%m-%d}'
keep_weekly: 4 unknown_unencrypted_repo_access_is_ok: true
keep_monthly: 6
prefix: '20'
consistency: keep_daily: 7
checks: keep_weekly: 4
- repository keep_monthly: 6
- archives
check_last: 3
prefix: '20'
hooks: checks:
before_backup: - name: repository
- echo -e "\n\n" - name: archives
- echo "#" check_last: 3
- echo "# `date` - Starting a backup job."
- echo "#" # log_json: true
after_backup: loki:
- echo "#" url: http://host:3100/loki/api/v1/push
- echo "# `date` - Backup created." labels:
- echo "#" app: borgmatic
on_error: config: __config
- echo "#" hostname: __hostname
- echo "# `date` - Error while creating a backup."
- echo "#"

View File

@@ -1,10 +1,10 @@
/usr/bin/borgmatic --stats -v 0 -c /config/home.yaml >> /log/home.log 2>&1 borgmatic --stats -v 0 -c /config/home.yaml >> /log/home.log 2>&1
/usr/bin/borgmatic --stats -v 0 -c /config/root.yaml >> /log/root.log 2>&1 borgmatic --stats -v 0 -c /config/root.yaml >> /log/root.log 2>&1
/usr/bin/borgmatic --stats -v 0 -c /config/opt.yaml >> /log/opt.log 2>&1 borgmatic --stats -v 0 -c /config/opt.yaml >> /log/opt.log 2>&1
/usr/bin/borgmatic --stats -v 0 -c /config/etc.yaml >> /log/etc.log 2>&1 borgmatic --stats -v 0 -c /config/etc.yaml >> /log/etc.log 2>&1
export REMOTE=/remote/server/bram export REMOTE=/remote/server/bram
mkdir -p ${REMOTE} mkdir -p ${REMOTE}
sshfs user@bram.veenboer.xyz:/media/helios/Bram ${REMOTE} sshfs user@bram.veenboer.xyz:/media/helios/Bram ${REMOTE}
/usr/bin/borgmatic --stats -v 0 -c /config/bram.yaml >> /log/bram.log 2>&1 borgmatic --stats -v 0 -c /config/bram.yaml >> /log/bram.log 2>&1
umount ${REMOTE} umount ${REMOTE}