Script for image synchronization enabled
This commit is contained in:
parent
8fd74f8242
commit
8c56288a43
@ -209,7 +209,7 @@ for (i = 0; i < images.size(); i++) {
|
|||||||
}
|
}
|
||||||
triggers {
|
triggers {
|
||||||
// Make a pause for sync during working hours
|
// Make a pause for sync during working hours
|
||||||
cron('H 3,7,9,20,23 * * *')
|
//cron('H 3,7,9,20,23 * * *')
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
shell("/usr/bin/env IMAGES_DEST=" + '${IMAGES_DEST}' + " IMAGE=${images[i]} FILE=${filename} /bin/sh ./scripts/sync_image")
|
shell("/usr/bin/env IMAGES_DEST=" + '${IMAGES_DEST}' + " IMAGE=${images[i]} FILE=${filename} /bin/sh ./scripts/sync_image")
|
||||||
|
@ -3,7 +3,7 @@ set -eu
|
|||||||
|
|
||||||
# Script to synchronize ALT Linux repository branches from remote
|
# Script to synchronize ALT Linux repository branches from remote
|
||||||
# sources to local.
|
# sources to local.
|
||||||
IMAGES_DEST="${IMAGES_DEST:-/data/mirrors/alt}"
|
IMAGES_DEST="${IMAGES_DEST:-/data/shared/iso}"
|
||||||
IMAGE=${IMAGE:-NULL}
|
IMAGE=${IMAGE:-NULL}
|
||||||
FILE=${FILE:-NULL}
|
FILE=${FILE:-NULL}
|
||||||
|
|
||||||
@ -12,8 +12,7 @@ mkdir -p "${IMAGES_DEST}"
|
|||||||
echo "Syncing: ${IMAGE}"
|
echo "Syncing: ${IMAGE}"
|
||||||
echo "Syncing to: ${IMAGES_DEST}/${FILE}"
|
echo "Syncing to: ${IMAGES_DEST}/${FILE}"
|
||||||
|
|
||||||
echo "Not implemented yet:"
|
wget -c -nc -O "${IMAGES_DEST}/${FILE}" "${IMAGE}"
|
||||||
echo "wget -O ${IMAGES_DEST}/${FILE} ${IMAGE}"
|
|
||||||
|
|
||||||
exit $?
|
exit $?
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user