#!/bin/bash # tiddlywiki server backup management set -e DATASTORE=/srv/dev-disk-by-uuid-45e2e732-9e00-4a82-a7cc-9c743e033671/datastore/tiddly/ XU4=root@192.168.1.5:/root/thedocks/tiddlywiki/data/ N2=root@192.168.1.4:/mnt/drive/tiddly PLUS=root@192.168.1.10:/home/odroid/thedocks/tiddlywiki/data sync(){ rsync -av --delete $1 $2 } echo "XU4 ->DATASTORE" sync $XU4 $DATASTORE echo "DATASTORE ->PLUS" sync $DATASTORE $PLUS