ansible/files/download/sync-up-downloads.sh.cc-rdu01

31 lines
1.3 KiB
Text
Raw Normal View History

2018-07-01 23:39:54 +00:00
#!/bin/bash
##
## This script is used to sync data from main download servers to
## secondary server at RDU community cage.
##
RSYNC='/usr/bin/rsync'
RS_OPT="-avSHP --numeric-ids"
RS_DEADLY="--delete --delete-excluded --delete-delay --delay-updates"
EPL_EXCLUDES=""
FED_EXCLUDES=""
SERVER=download-ib01.fedoraproject.org
2018-07-01 23:39:54 +00:00
# http://dl.fedoraproject.org/pub/epel/
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${EPL_EXCLUDES} ${SERVER}::fedora-epel/ /srv/pub/epel/ | tail -n2 | logger -p local0.notice -t rsync_updates_epel
# http://dl.fedoraproject.org/pub/fedora/
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${FED_EXCLUDES} ${SERVER}::fedora-enchilada0/ /srv/pub/fedora/ | tail -n2 | logger -p local0.notice -t rsync_updates_fedora
# http://dl.fedoraproject.org/pub/fedora-secondary/
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${FED_EXCLUDES} ${SERVER}::fedora-secondary0/ /srv/pub/fedora-secondary/ | tail -n2 | logger -p local0.notice -t rsync_updates_fedora_2nd
# CentOS
2018-07-20 13:40:54 +00:00
${RSYNC} ${RS_OPT} ${RD_DEADLY} master-1.centos.org::CentOS-community-cage/centos/ /srv/pub/centos/ | tail -n2 | logger -p local0.notice -t rsync_centos
# CentOS-altarch
${RSYNC} ${RS_OPT} ${RD_DEADLY} master-1.centos.org::CentOS-community-cage/altarch/ /srv/pub/centos-altarch/ | tail -n2 | logger -p local0.notice -t rsync_centos_alt
2018-07-01 23:39:54 +00:00
# Let MM know I'm all up to date
#/usr/bin/report_mirror