Update centos-10-sync script to rsync
Signed-off-by: james02135 <james02135@hotmail.com> Change DESTDIR to previously used directory, exlcude debug directory Signed-off-by: james02135 <james02135@hotmail.com>
This commit is contained in:
parent
bba5d4340e
commit
decfe3e771
1 changed files with 16 additions and 19 deletions
|
@ -1,21 +1,18 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
#Sync using reposync instead of rsync until available
|
## Set up variables we use
|
||||||
SERVER=composes.stream.centos.org
|
RSYNC='/usr/bin/rsync'
|
||||||
TOPDIR=stream-10/production/latest-CentOS-Stream/compose
|
RS_OPT="-avSHP --numeric-ids"
|
||||||
|
RS_DEADLY="--delete --delete-delay --delay-updates"
|
||||||
## mirror CentOS-10
|
CENT_EXCLUDES="--exclude=isos --exclude=kickstart --exclude=images --exclude=debug"
|
||||||
|
|
||||||
DESTDIR=/mnt/fedora/app/fi-repo/centos/centos-10
|
SERVER=centos-master01.iad2.fedoraproject.org
|
||||||
|
|
||||||
mkdir -p ${DESTDIR}
|
## Mirror CentOS-10-Stream
|
||||||
|
|
||||||
for basearch in aarch64 ppc64le s390x x86_64
|
RSYNC_DESTDIR=/mnt/fedora/app/fi-repo/centos/centos-10/
|
||||||
do
|
RSYNC_MOD="CentOS-Stream-Ref/10-stream/"
|
||||||
for repo in BaseOS AppStream CRB
|
|
||||||
do
|
mkdir -p ${RSYNC_DESTDIR}
|
||||||
mkdir -p $DESTDIR/$repo/$basearch
|
|
||||||
cd $DESTDIR/$repo/$basearch
|
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${CENT_EXCLUDES} ${SERVER}::${RSYNC_MOD} ${RSYNC_DESTDIR}
|
||||||
reposync --download-metadata --disablerepo=* --repofrompath=os,https://$SERVER/$TOPDIR/$repo/$basearch/os/ --enablerepo=os
|
|
||||||
done
|
|
||||||
done
|
|
Loading…
Add table
Add a link
Reference in a new issue