From: Alfredo Deza Date: Thu, 7 Jan 2016 21:37:59 +0000 (-0500) Subject: create the sync-push script X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=eece34c21614337b4866da72d7323fa4e86892af;p=ceph-build.git create the sync-push script Signed-off-by: Alfredo Deza --- diff --git a/scripts/sync-push b/scripts/sync-push new file mode 100644 index 00000000..ca19a02c --- /dev/null +++ b/scripts/sync-push @@ -0,0 +1,27 @@ +#!/bin/bash +# This script will push repository files from the signer box to the upstream repositories. +# By default it will sync all releases defined, but can optionally take one or more +# releases to sync: +# +# sync-push hammer infernalis +# +# Since the binaries are created with a different repository layout, this +# script maps directories like "centos/6" to "rpm-$release/el6" + +releases=${*:-"firefly giant hammer infernalis testing"} + +ceph_sync() { + release=$1 + deb_cmd="/opt/repos/ceph/$release/debian/jessie/* dhc-user@download.ceph.com:/home/dhc-user/repos/debian-$release/" + rsync --progress -avr $deb_cmd + + el6_cmd="/opt/repos/ceph/$release/centos/6/* dhc-user@download.ceph.com:/home/dhc-user/repos/rpm-$release/el6/" + el7_cmd="/opt/repos/ceph/$release/centos/7/* dhc-user@download.ceph.com:/home/dhc-user/repos/rpm-$release/el7/" + rsync --progress -avr $el6_cmd + rsync --progress -avr $el7_cmd +} + +for i in "${releases[@]}" +do + ceph_sync $i +done