refactor: update skeleton and scripts

This commit is contained in:
Strix 2023-10-18 20:58:24 +02:00
parent fad2dcf339
commit 07994c11c5
No known key found for this signature in database
GPG key ID: 49B2E37B8915B774
7 changed files with 18 additions and 24 deletions

View file

@ -0,0 +1,17 @@
#!/bin/sh
ntfy() {
sh /opt/scripts/ntfy.sh -s "/neb/secrets/ntfy/ixvd-backups" -u "https://push.ixvd.net/ixvd-backups" "$@"
}
ntfy -m "performing backup..."
if restic \
-r "sftp://ixvd_backup_storage//$(hostname)" \
-p "/neb/secrets/restic/$(hostname).secret" \
backup \
--tag auto \
/srv /home /etc; then
ntfy -m "backup succeeded"
else
ntfy -m "backup failed" -e "warning,skull"
fi