Ajout : remote/duplicity .
[lhc/ateliers.git] / remote / backup-fetch
index b8c5ccd..b888830 100755 (executable)
@@ -9,10 +9,10 @@ path=${1-}; test ! "${1+set}" || shift
 date=${date:-$(date +'%Y%m%d+%H%M%S%z')}
 mkdir -p \
  "$tool"/var/backup/current \
- "$tool"/var/backup/"$date"
+ "$tool"/var/backup/old/"$date"
 rsync \
  --backup \
- --backup-dir ../"$date" \
+ --backup-dir ../old/"$date" \
  --compress-level=0 \
  --delete \
  --delete-during \
@@ -22,8 +22,11 @@ rsync \
  --partial \
  ${TRACE:+--progress} \
  --recursive \
+ --relative \
  --rsh "$tool/remote/ssh -o Compression=no" \
  --times \
  "$@" \
- backup@"$local_fqdn":data/"$path" \
+ backup@"$local_fqdn":data/"$path" :archive/"$path" \
  "$tool"/var/backup/current
+#rmdir --ignore-fail-on-non-empty \
+# "$tool"/var/backup/old/"$date"