feat: adding ntfy to backup scripts

This commit is contained in:
Bruno F. Fontes 2023-06-28 11:32:30 -03:00
parent 79860803ee
commit 108e82c07a
Signed by: brunofontes
GPG Key ID: 4DAA810052CF68B6
3 changed files with 7 additions and 2 deletions

View File

@ -133,7 +133,8 @@ echo -e "${green}`date +%r` - Backup finished. Please, verify your log files.\e[
echo "$ActiveDisk" > .lastDisk
# /usr/bin/curl -d "Backup HD: Completed" ntfy.sh/bft >/dev/null 2>&1 &
/home/bruno/Apps/linuxShortcuts/ntfy.sh -t "Michelle Backup Completed!" a "floppy_disk" "Close the window and remove the disk..." >/dev/null 2>&1 &
/home/bruno/Apps/linuxShortcuts/ntfy.sh --title "Michelle Backup Completed\!" --tags "floppy_disk" "Close the window and remove the disk..." >/dev/null 2>&1 &
kdialog --title "Backup Complete" --msgbox "Backup finished successfully"
echo
echo "Backup on $device is finished. Press any key to close..."

View File

@ -1 +1 @@
1
2

View File

@ -13,14 +13,17 @@ if [[ -z $CONTABO_BACKUP_PATH ]]; then
fi
sleep 60
ntfy="/home/bruno/Apps/linuxShortcuts/ntfy.sh --title Backup"
OXO_PATH="/home/bruno/Backups/OXOwebsite/"
# Backup Contabo
echo "Backuping Contabo..."
ntfy "Starting Contabo..."
/bin/rsync --archive --backup --exclude "files/nextcloud*" --rsh=ssh backupContabo:/home/bruno/backups/* $CONTABO_BACKUP_PATH
# Backup Gitea
echo "Backuping Gitea..."
ntfy "Starting GoogleMicro..."
/bin/rsync --archive --backup --rsh=ssh bkpgitea:/home/brunofontes/ttt/ /home/bruno/Backups/gitea/
# Backup OXO Files
@ -52,3 +55,4 @@ find $CONTABO_BACKUP_PATH/mail -type f -name "*.*" -mtime +20 -delete
find $CONTABO_BACKUP_PATH/ -type f -name "*.*" -mtime +120 -delete
find /home/bruno/Backups/gitea/ -type f -name "*.zip" -mtime +15 -delete
ntfy "Websites Backup Finished"