I’ve just configured this.
rclone for BackBlaze B2
#Let’s set some variables
DATA="/mnt/goodies /mnt/private /mnt/music"
PRUNEDATES=”–keep-daily=7 --keep-weekly=4 --keep-monthly=12"
#Is backup mounted? It should have happened at boot via SystemD
if [ mount | grep backup | wc -l == “1” ]
#Build a bear, er, command
$BORG create $REPO::$TODAY $DATA $EXCLUDE
#and then we prune
$BORG prune $REPO $PRUNEDATES
#and finally, let’s chuck this up to the ‘cloud’
rclone sync $REPOPATH $CLOUDDEST -v
echo /mnt/backup isn’t mounted, this is an issue
sendEmail -f My@Address.me -t My@Address.me -u No Backup -m Backup did not happen. Check it. -s SMTP -xu SMTP-USER -xp SMTP-PASSWD
That’s it. Depends on sendemail, borgbackup and rclone.
If you want to restore use the local repo you’ll be keeping for borg, else if your house burns down you will need to pull the whole repo back down somewhere and do a restore.
I’ve set B2 to only keep the latest file and no backups as Borg Backup is doing all that for me.