Script to syncronize repos on PVE added
This commit is contained in:
parent
e062b82396
commit
c0db3ed2f2
19
scripts/sync_alt_repo
Normal file
19
scripts/sync_alt_repo
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
MIRRORS_SRC="${MIRRORS_SRC:-ftp.altlinux.org}"
|
||||||
|
MIRRORS_DEST="${MIRRORS_DEST:-/data/mirrors/alt}"
|
||||||
|
PLATFORM="${PLATFORM:-p8}"
|
||||||
|
|
||||||
|
mkdir -p "${MIRRORS_DEST}/${PLATFORM}"
|
||||||
|
|
||||||
|
/usr/bin/rsync \
|
||||||
|
--timeout=6000 \
|
||||||
|
-avlpztc \
|
||||||
|
-P \
|
||||||
|
--stats \
|
||||||
|
--delete-after \
|
||||||
|
--exclude 'SRPMS*/' \
|
||||||
|
"rsync://${MIRRORS_SRC}/altlinux/${PLATFORM}/branch" \
|
||||||
|
"${MIRRORS_DEST}/${PLATFORM}/" > "${MIRRORS_DEST}/${PLATFORM}.log" 2>&1
|
||||||
|
|
Loading…
Reference in New Issue
Block a user