From 2ba6ed6fad84b8b14a58df8d149f3ba9a6960b27 Mon Sep 17 00:00:00 2001 From: Joerg Jaspert Date: Wed, 22 Oct 2008 00:40:56 +0200 Subject: only trigger slave mirrors if we got pushed for stage2 or all Signed-off-by: Joerg Jaspert --- bin/ftpsync | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'bin/ftpsync') diff --git a/bin/ftpsync b/bin/ftpsync index feda3fe..968394c 100755 --- a/bin/ftpsync +++ b/bin/ftpsync @@ -410,15 +410,18 @@ if [ "xtruex" = "x${SYNCCALLBACK}x" ]; then fi if [ x${HUB} = "xtrue" ]; then - log "Trigger slave mirrors" - ${BASEDIR}/bin/runmirrors - log "Trigger slave done" - - HOOK=( - HOOKNR=5 - HOOKSCR=${HOOK5} - ) - hook $HOOK + # Only trigger slave mirrors if we had a push for stage2 or all + if [ "xtruex" = "x${SYNCSTAGE2}x" ] || [ "xtruex" = "x${SYNCALL}x" ]; then + log "Trigger slave mirrors" + ${BASEDIR}/bin/runmirrors + log "Trigger slave done" + + HOOK=( + HOOKNR=5 + HOOKSCR=${HOOK5} + ) + hook $HOOK + fi fi # All done, rest is done by cleanup hook. -- cgit v1.2.3