diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2010-11-14 10:48:41 -0200 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2010-11-14 10:48:41 -0200 |
commit | d5fcbe970289d8246e6e3db4249a0bb6dc75cfb8 (patch) | |
tree | 197988ed5d6a9713f5bbdad6f1d1decf46a04942 | |
parent | 1c975d65f221eb78baf2808893c059091740da2a (diff) | |
download | hydra-d5fcbe970289d8246e6e3db4249a0bb6dc75cfb8.tar.gz hydra-d5fcbe970289d8246e6e3db4249a0bb6dc75cfb8.tar.bz2 |
Deploying to a specific commit
-rwxr-xr-x | share/hydra/deploy | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/share/hydra/deploy b/share/hydra/deploy index 81f29ca..93f2b51 100755 --- a/share/hydra/deploy +++ b/share/hydra/deploy @@ -9,6 +9,7 @@ hydra_config_load # Command line arguments ORIGIN="$1" +COMMIT="1c975d65f221eb78baf2808893c059091740da2a" # Build node list NODES="`hydra $HYDRA nodes`" @@ -19,17 +20,17 @@ if [ -z "$ORIGIN" ]; then fi # Deploy -# TODO: code signature for node in $NODES; do echo "Deploying to $node..." ssh -o ConnectTimeout=15 $node <<EOF ##### BEGIN REMOTE SCRIPT ##### if [ ! -d /usr/local/hydra ]; then sudo git clone $ORIGIN /usr/local/hydra + ( cd /usr/local/hydra ; git reset --hard $COMMIT ) sudo ln -s /usr/local/hydra/hydra /usr/local/sbin/hydra sudo ln -s /usr/local/hydra/hydra /usr/local/sbin/hydractl else - ( cd /usr/local/hydra && sudo git pull ) + ( cd /usr/local/hydra ; sudo git pull ; git reset --hard $COMMIT ) fi ##### END REMOTE SCRIPT ####### EOF |