and we have some adds
This commit is contained in:
parent
10e7fcd6e3
commit
cda0eebc5b
4 changed files with 32 additions and 4 deletions
|
@ -1,3 +1,4 @@
|
||||||
# run twice daily rsync of download. but lock it
|
# run twice daily rsync of download. but lock it
|
||||||
MAILTO=smooge@gmail.com
|
MAILTO=smooge@gmail.com
|
||||||
00 11,23 * * * root /usr/local/bin/lock-wrapper sync-up-downloads "/usr/local/bin/sync-up-downloads"
|
00 11,23 * * * root /usr/local/bin/lock-wrapper sync-up-downloads "/usr/local/bin/sync-up-downloads"
|
||||||
|
00 23 * * * root /usr/local/bin/lock-wrapper sync-up-archives "/usr/local/bin/sync-up-archives"
|
||||||
|
|
28
files/download/sync-up-archives.sh.ib01
Executable file
28
files/download/sync-up-archives.sh.ib01
Executable file
|
@ -0,0 +1,28 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
##
|
||||||
|
## This script is used to sync data from main download servers to
|
||||||
|
## secondary server at ibiblio.
|
||||||
|
##
|
||||||
|
|
||||||
|
RSYNC='/usr/bin/rsync'
|
||||||
|
RS_OPT="-avSHP --numeric-ids"
|
||||||
|
RS_DEADLY="--delete --delete-excluded --delete-delay --delay-updates"
|
||||||
|
ALT_EXCLUDES=""
|
||||||
|
EPL_EXCLUDES=""
|
||||||
|
FED_EXCLUDES=""
|
||||||
|
|
||||||
|
LAST_SYNC='/usr/local/bin/last-sync'
|
||||||
|
|
||||||
|
SERVER=dl.fedoraproject.org
|
||||||
|
|
||||||
|
# The Buffet.
|
||||||
|
#${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-buffet0/ /srv/pub/ | tail -n2 | logger -p local0.notice -t rsync_updates_alt_stg
|
||||||
|
|
||||||
|
# Archives
|
||||||
|
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-archive/ /srv/pub/archive/ | tail -n2 | logger -p local0.notice -t rsync_archive
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Let MM know I'm all up to date
|
||||||
|
#/usr/bin/report_mirror
|
|
@ -27,10 +27,6 @@ ${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-epel0/ /srv/p
|
||||||
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-enchilada0/ /srv/pub/fedora/ | tail -n2 | logger -p local0.notice -t rsync_fedora
|
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-enchilada0/ /srv/pub/fedora/ | tail -n2 | logger -p local0.notice -t rsync_fedora
|
||||||
# Secondary
|
# Secondary
|
||||||
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-secondary/ /srv/pub/fedora-secondary/ | tail -n2 | logger -p local0.notice -t rsync_2nd
|
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-secondary/ /srv/pub/fedora-secondary/ | tail -n2 | logger -p local0.notice -t rsync_2nd
|
||||||
# Archives
|
|
||||||
${RSYNC} ${RS_OPT} ${RS_DEADLY} ${ALT_EXCLUDES} ${SERVER}::fedora-archive/ /srv/pub/archive/ | tail -n2 | logger -p local0.notice -t rsync_archive
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Let MM know I'm all up to date
|
# Let MM know I'm all up to date
|
||||||
#/usr/bin/report_mirror
|
#/usr/bin/report_mirror
|
||||||
|
|
|
@ -53,6 +53,9 @@
|
||||||
- name: put in script for syncing on download-ib01
|
- name: put in script for syncing on download-ib01
|
||||||
copy: src="{{ files }}/download/sync-up-downloads.sh.ib01" dest=/usr/local/bin/sync-up-downloads owner=root group=root mode=755
|
copy: src="{{ files }}/download/sync-up-downloads.sh.ib01" dest=/usr/local/bin/sync-up-downloads owner=root group=root mode=755
|
||||||
when: inventory_hostname == 'download-ib01.fedoraproject.org'
|
when: inventory_hostname == 'download-ib01.fedoraproject.org'
|
||||||
|
- name: put in script for syncing on download-ib01
|
||||||
|
copy: src="{{ files }}/download/sync-up-archives.sh.ib01" dest=/usr/local/bin/sync-up-archives owner=root group=root mode=755
|
||||||
|
when: inventory_hostname == 'download-ib01.fedoraproject.org'
|
||||||
- name: put in cron job for syncing
|
- name: put in cron job for syncing
|
||||||
copy: src="{{ files }}/download/download-sync.cron" dest=/etc/cron.d/download-sync owner=root group=root mode=644
|
copy: src="{{ files }}/download/download-sync.cron" dest=/etc/cron.d/download-sync owner=root group=root mode=644
|
||||||
when: datacenter == 'ibiblio'
|
when: datacenter == 'ibiblio'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue