Created
December 9, 2010 15:33
-
-
Save noahd1/734839 to your computer and use it in GitHub Desktop.
cloudssh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# usage: cloudssh | |
# ssh's into the build master | |
# usage: cloudssh {0|1|2} | |
# ssh's into one of the testjour slaves | |
if [[ -s "$HOME/.rvm/scripts/rvm" ]] ; then | |
# First try to load from a user install | |
source "$HOME/.rvm/scripts/rvm" | |
elif [[ -s "/usr/local/rvm/scripts/rvm" ]] ; then | |
# Then try to load from a root install | |
source "/usr/local/rvm/scripts/rvm" | |
else | |
printf "ERROR: An RVM installation was not found.\n" | |
fi | |
cd ~/p/weplay-cloudbuild | |
case "$1" in | |
"") | |
./bin/cloud ssh | |
;; | |
[0-2]) | |
./bin/cloud ssh -n testjour_slaves -i $1 | |
;; | |
*) | |
echo $"Usage: $0 {0|1|2}" | |
exit 1 | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment