ceph/push.sh
Sage Weil b81273d5ec debian: make helper scripts remember most recent release
So you don't have to cut&paste it on the command line

Signed-off-by: Sage Weil <sage@newdream.net>
2010-07-08 14:27:57 -07:00

23 lines
467 B
Bash
Executable File

#!/bin/bash
set -e
remote=ceph.newdream.net
vers=$1
[ -z "$vers" ] && [ -e .last_release ] && vers=`cat .last_release`
[ -z "$vers" ] && echo specify version && exit 1
[ ! -d release/$vers ] && echo release/$vers dne && exit 1
echo version $vers
shift
if [ -z "$*" ]; then
echo pushing $vers
rsync -auv release/$vers/ $remote:release/$vers
else
for e in $*; do
echo pushing $vers/*.$e
rsync -auv release/$vers/*.$e $remote:release/$vers
done
fi