sync to new location in loch

This commit is contained in:
Nico Schottelius 2019-04-17 21:01:17 +02:00
parent acaf59cee6
commit 5d32e05854

13
sync-to
View file

@ -6,20 +6,11 @@ set -x
dsthost="$1"; shift dsthost="$1"; shift
case "$dsthost" in case "$dsthost" in
loch|rloch) loch|rloch)
dst=root@loch.place5.ungleich.ch:/home/services/backup/notebook-manuell/home/users/nico/ dst=root@loch.place7.ungleich.ch:/raid/${hostname}/incoming
;; ;;
nico-vm) nico-vm)
dst=nico-vm.schottelius.org:/data dst=nico-vm.schottelius.org:/data
;; ;;
freiheit)
dst=freiheit:
;;
local)
dst=root@192.168.0.20:/home/services/backup/notebook-manuell/home/users/nico/
;;
nico-data)
dst=nico-data.schottelius.org:/home/nico
;;
*) *)
echo "Unknown $1" >&2 echo "Unknown $1" >&2
exit 1 exit 1
@ -28,8 +19,8 @@ esac
start=$(date) start=$(date)
rsync -avS --delete --progress \ rsync -avS --delete --progress \
--exclude-from=/home/users/nico/.ccollect/defaults/exclude \
--exclude /.cache \ --exclude /.cache \
--exclude /.cdist/cache \
--exclude ~/temp/ \ --exclude ~/temp/ \
"$@" \ "$@" \
~/ "$dst" ~/ "$dst"