mirror of
https://github.com/FAUSheppy/no-secrets-athq-ansible
synced 2025-12-10 13:48:33 +01:00
feat: caldav backup monitoring
This commit is contained in:
12
roles/backup-vm/ths_cal_backup.sh
Normal file
12
roles/backup-vm/ths_cal_backup.sh
Normal file
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
BACKUP_NAME=backup_$(date +%Y%m%d).zip
|
||||
mkdir -p ~/ths_caldav_backups/
|
||||
vdirsyncer -c vsyncdir.conf sync
|
||||
zip -q -r ~/ths_caldav_backups/${BACKUP_NAME} ~/ths-caldav
|
||||
~/backups/backup-tools/backup_manager.py ~/ths_caldav_backups/ --debug
|
||||
|
||||
curl -H "Content-Type: application/json" \
|
||||
-X POST https://async-icinga.atlantishq.de/ \
|
||||
-d '{ "service" : "ths_caldav_backup", "token" : "HISTORY_PURGED_SECRET", "status" : "OK", "info" : "" }'
|
||||
Reference in New Issue
Block a user