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
|
||||
|
||||
#Sync using reposync instead of rsync until available
|
||||
SERVER=composes.stream.centos.org
|
||||
TOPDIR=stream-10/production/latest-CentOS-Stream/compose
|
||||
## Set up variables we use
|
||||
RSYNC='/usr/bin/rsync'
|
||||
RS_OPT="-avSHP --numeric-ids"
|
||||
RS_DEADLY="--delete --delete-delay --delay-updates"
|
||||
CENT_EXCLUDES="--exclude=isos --exclude=kickstart --exclude=images --exclude=debug"
|
||||
|
||||
## mirror CentOS-10
|
||||
SERVER=centos-master01.iad2.fedoraproject.org
|
||||
|
||||
DESTDIR=/mnt/fedora/app/fi-repo/centos/centos-10
|
||||
## Mirror CentOS-10-Stream
|
||||
|
||||
mkdir -p ${DESTDIR}
|
||||
RSYNC_DESTDIR=/mnt/fedora/app/fi-repo/centos/centos-10/
|
||||
RSYNC_MOD="CentOS-Stream-Ref/10-stream/"
|
||||
|
||||
for basearch in aarch64 ppc64le s390x x86_64
|
||||
do
|
||||
for repo in BaseOS AppStream CRB
|
||||
do
|
||||
mkdir -p $DESTDIR/$repo/$basearch
|
||||
cd $DESTDIR/$repo/$basearch
|
||||
reposync --download-metadata --disablerepo=* --repofrompath=os,https://$SERVER/$TOPDIR/$repo/$basearch/os/ --enablerepo=os
|
||||
done
|
||||
done
|
||||
mkdir -p ${RSYNC_DESTDIR}
|
||||
|
||||
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${CENT_EXCLUDES} ${SERVER}::${RSYNC_MOD} ${RSYNC_DESTDIR}
|
Loading…
Add table
Add a link
Reference in a new issue