diff --git a/scripts/sync_alt_repo b/scripts/sync_alt_repo index 2986753..41fc405 100644 --- a/scripts/sync_alt_repo +++ b/scripts/sync_alt_repo @@ -8,7 +8,13 @@ MIRRORS_SRC="${MIRRORS_SRC:-ftp.altlinux.org}" MIRRORS_DEST="${MIRRORS_DEST:-/data/mirrors/alt}" PLATFORM="${PLATFORM:-p8}" -mkdir -p "${MIRRORS_DEST}/${PLATFORM}" +RSYNC_SRC="rsync://${MIRRORS_SRC}/altlinux/${PLATFORM}/branch" +RSYNC_DST="${MIRRORS_DEST}/${PLATFORM}/" + +mkdir -p "${RSYNC_DST}" + +echo "Rsyncing from: ${RSYNC_SRC}" +echo "Rsyncing to: ${RSYNC_DST}" /usr/bin/rsync \ --timeout=6000 \ @@ -17,6 +23,6 @@ mkdir -p "${MIRRORS_DEST}/${PLATFORM}" --stats \ --delete-after \ --exclude 'SRPMS*/' \ - "rsync://${MIRRORS_SRC}/altlinux/${PLATFORM}/branch" \ - "${MIRRORS_DEST}/${PLATFORM}/" + "${RSYNC_SRC}" \ + "${RSYNC_DST}/"