diff --git a/configure_jenkins.groovy b/configure_jenkins.groovy index 46f2376..2e08740 100644 --- a/configure_jenkins.groovy +++ b/configure_jenkins.groovy @@ -209,7 +209,7 @@ for (i = 0; i < images.size(); i++) { } triggers { // Make a pause for sync during working hours - cron('H 3,7,9,20,23 * * *') + //cron('H 3,7,9,20,23 * * *') } steps { shell("/usr/bin/env IMAGES_DEST=" + '${IMAGES_DEST}' + " IMAGE=${images[i]} FILE=${filename} /bin/sh ./scripts/sync_image") diff --git a/scripts/sync_image b/scripts/sync_image index c12c233..b8a527c 100644 --- a/scripts/sync_image +++ b/scripts/sync_image @@ -3,7 +3,7 @@ set -eu # Script to synchronize ALT Linux repository branches from remote # sources to local. -IMAGES_DEST="${IMAGES_DEST:-/data/mirrors/alt}" +IMAGES_DEST="${IMAGES_DEST:-/data/shared/iso}" IMAGE=${IMAGE:-NULL} FILE=${FILE:-NULL} @@ -12,8 +12,7 @@ mkdir -p "${IMAGES_DEST}" echo "Syncing: ${IMAGE}" echo "Syncing to: ${IMAGES_DEST}/${FILE}" -echo "Not implemented yet:" -echo "wget -O ${IMAGES_DEST}/${FILE} ${IMAGE}" +wget -c -nc -O "${IMAGES_DEST}/${FILE}" "${IMAGE}" exit $?