From 83c98bce49fad95a56e4d52e6dd9d2558439f55a Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Mon, 17 Dec 2012 14:45:46 +0100 Subject: [PATCH] Add --hard-links to rsync options --- modules/roles/files/static-mirroring/static-master-ssh-wrap | 2 +- .../roles/files/static-mirroring/static-master-update-component | 2 +- modules/roles/files/static-mirroring/static-mirror-run | 2 +- modules/roles/files/static-mirroring/static-mirror-ssh-wrap | 2 +- modules/roles/manifests/static_mirror.pp | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/modules/roles/files/static-mirroring/static-master-ssh-wrap b/modules/roles/files/static-mirroring/static-master-ssh-wrap index 6041a567b..9c543bf0f 100755 --- a/modules/roles/files/static-mirroring/static-master-ssh-wrap +++ b/modules/roles/files/static-mirroring/static-master-ssh-wrap @@ -73,7 +73,7 @@ lock() { do_rsync() { local remote_host="$1"; shift - local args="--server --sender -vltrze.iLsf --safe-links ." + local args="--server --sender -vlHtrze.iLsf --safe-links ." if [ "$*" = "$args -new-/" ] || [ "$*" = "$args ./-new-/" ] ; then local path="$BASEDIR/current-push" info "serving $remote_host with $path" diff --git a/modules/roles/files/static-mirroring/static-master-update-component b/modules/roles/files/static-mirroring/static-master-update-component index af8a5f7e2..6f7ff03aa 100755 --- a/modules/roles/files/static-mirroring/static-master-update-component +++ b/modules/roles/files/static-mirroring/static-master-update-component @@ -110,7 +110,7 @@ echo "$0: Got them." echo "$0: Updating master copy of $component..." rsync --delete \ -trz \ - --links --safe-links \ + --links --hard-links --safe-links \ --link-dest="$tgt" \ "$src/." "$tmpdir_new/." echo "$0: Done. Committing." diff --git a/modules/roles/files/static-mirroring/static-mirror-run b/modules/roles/files/static-mirroring/static-mirror-run index b2bc078e1..038700ddb 100755 --- a/modules/roles/files/static-mirroring/static-mirror-run +++ b/modules/roles/files/static-mirroring/static-mirror-run @@ -64,7 +64,7 @@ if [ -z "$BASEDIR" ]; then usage >&2; exit 1; fi if [ -z "$SYNC_SOURCE" ]; then usage >&2; exit 1; fi RSYNC="rsync" -RSYNC_BASE_OPTIONS="-rtvz --delete --links --safe-links" +RSYNC_BASE_OPTIONS="-rtvz --delete --links --hard-links --safe-links" RSYNC_SSH_OPTIONS="ssh -o AddressFamily=inet -o BatchMode=yes" LOGDIR="$HOME/logs" diff --git a/modules/roles/files/static-mirroring/static-mirror-ssh-wrap b/modules/roles/files/static-mirroring/static-mirror-ssh-wrap index 911487902..3b1d99896 100755 --- a/modules/roles/files/static-mirroring/static-mirror-ssh-wrap +++ b/modules/roles/files/static-mirroring/static-mirror-ssh-wrap @@ -76,7 +76,7 @@ do_rsync() { if [ -e "$COMPONENTLIST" ]; then for path in $(awk -v host="$(hostname -f)" '$2 == host {print $3}' $COMPONENTLIST); do - allowed_rsyncs+=("--server --sender -ltrze.iLsf --safe-links . $path/.") + allowed_rsyncs+=("--server --sender -ltHrze.iLsf --safe-links . $path/.") done fi for cmd_idx in ${!allowed_rsyncs[*]}; do diff --git a/modules/roles/manifests/static_mirror.pp b/modules/roles/manifests/static_mirror.pp index cc9b21066..c98464c37 100644 --- a/modules/roles/manifests/static_mirror.pp +++ b/modules/roles/manifests/static_mirror.pp @@ -40,7 +40,7 @@ class roles::static_mirror { content => template('roles/static-mirroring/vhost/planet.debian.org.erb'), } - apache2::site { '10-static-vhosts-simple': + apache2::site { '010-static-vhosts-simple': site => "static-vhosts-simple", content => template('roles/static-mirroring/vhost/static-vhosts-simple.erb'), } -- 2.20.1