This commit is contained in:
iFargle 2023-12-25 20:18:14 +09:00
parent b8517efaaf
commit 76274cd028

View file

@ -130,6 +130,7 @@ payload="{\"message\": \"Backup completed\nDate: `date`\n`df -h | grep sda`\n`df
curl -X "POST" "https://gotify.sysctl.io/message" -H "accept: application/json" -H "Content-Type: application/json" -H "X-Gotify-Key: $GOTIFY_TOKEN" -d "$payload" curl -X "POST" "https://gotify.sysctl.io/message" -H "accept: application/json" -H "Content-Type: application/json" -H "X-Gotify-Key: $GOTIFY_TOKEN" -d "$payload"
''; '';
rsync-data-vol = pkgs.writeScriptBin "rsync-data-vol" '' rsync-data-vol = pkgs.writeScriptBin "rsync-data-vol" ''
#!${pkgs.stdenv.shell} #!${pkgs.stdenv.shell}
# Send the gotify notification: # Send the gotify notification:
@ -194,7 +195,6 @@ echo "Sending completion message"
payload="{\"message\": \"Data Vol Backup completed\nDate: `date`\n`df -h | grep sda`\n`df -h | grep sdb`\n`df -h | grep sdc`\", \"priority\": 2,\"title\": \"backups-rpi4: Data Vol Backup Complete\"}" payload="{\"message\": \"Data Vol Backup completed\nDate: `date`\n`df -h | grep sda`\n`df -h | grep sdb`\n`df -h | grep sdc`\", \"priority\": 2,\"title\": \"backups-rpi4: Data Vol Backup Complete\"}"
curl -X "POST" "https://gotify.sysctl.io/message" -H "accept: application/json" -H "Content-Type: application/json" -H "X-Gotify-Key: $GOTIFY_TOKEN" -d "$payload" curl -X "POST" "https://gotify.sysctl.io/message" -H "accept: application/json" -H "Content-Type: application/json" -H "X-Gotify-Key: $GOTIFY_TOKEN" -d "$payload"
'';
''; '';
in in
{ {