Merge ~pjdc/ubuntu-mirror-charm/+git/ubuntu-mirror-charm:trigger-1stage into ubuntu-mirror-charm:master

Proposed by Paul Collins
Status: Merged
Approved by: Paul Collins
Approved revision: 766557a475d6629f8c6ac64bbbe82b499e9caebf
Merged at revision: 44dcb22b1bd759debe6f98bc5e4de74077b69feb
Proposed branch: ~pjdc/ubuntu-mirror-charm/+git/ubuntu-mirror-charm:trigger-1stage
Merge into: ubuntu-mirror-charm:master
Diff against target: 17 lines (+7/-0)
1 file modified
files/mirror-1stage.sh (+7/-0)
Reviewer Review Type Date Requested Status
Haw Loeung +1 Approve
Canonical IS Reviewers Pending
Review via email: mp+391908@code.launchpad.net

Commit message

implement downstream triggering for mirror-1stage.sh

To post a comment you must log in.
Revision history for this message
Canonical IS Mergebot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
Haw Loeung (hloeung) wrote :

LGTM

review: Approve (+1)
Revision history for this message
Canonical IS Mergebot (canonical-is-mergebot) wrote :

Change successfully merged at revision 44dcb22b1bd759debe6f98bc5e4de74077b69feb

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/files/mirror-1stage.sh b/files/mirror-1stage.sh
2index 6348aa1..0f97175 100755
3--- a/files/mirror-1stage.sh
4+++ b/files/mirror-1stage.sh
5@@ -76,5 +76,12 @@ rsync --verbose --recursive --times --links --hard-links \
6
7 install -d "${DEST_DIR}/.trace/"
8 date -u > "${DEST_DIR}/.trace/${role}-${myhostname}"
9+
10+if [ -n "${DOWNSTREAM_MIRRORS}" -a -n "${TRIGGER_KEYFILE}" ]; then
11+ t=15m
12+ log "== Triggering downstream mirrors (will give up after $t) =="
13+ timeout $t ${SCRIPT_DIR}/trigger-downstream-mirrors.sh $role $TRIGGER_KEYFILE $DOWNSTREAM_MIRRORS
14+fi
15+
16 savelog ${logfile} > /dev/null 2>&1
17 rm -f ${lockpath} > /dev/null 2>&1

Subscribers

People subscribed via source and target branches