summaryrefslogtreecommitdiff
path: root/src/manage.sh
diff options
context:
space:
mode:
Diffstat (limited to 'src/manage.sh')
-rwxr-xr-xsrc/manage.sh10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/manage.sh b/src/manage.sh
index 92596af..29d0c85 100755
--- a/src/manage.sh
+++ b/src/manage.sh
@@ -65,6 +65,13 @@ clean_all() {
done
}
+wipe_all() {
+ for machine in `grep "^Host" ssh.config | awk '{ print($2) }'`; do
+ echo "wipeing files belonging to planet '$1' from $machine ... "
+ ssh -i "$SSH_KEY" -F "$SSH_CONFIG" $SSH_USER@"$machine" wipe "$1"
+ done
+}
+
generate_instance_list() {
machine=$1
@@ -135,9 +142,10 @@ case "$1" in
wipe)
if [ -z "$2" ]; then
echo "Usage: $0 wipe <planet name>"
+ exit 1
fi
echo "wipeing configuration for from all machines inside ssh-config ..."
- wipe_all
+ wipe_all "$2"
;;
start)
echo "Start manager and worker on all machines ..."