summaryrefslogtreecommitdiff
path: root/src/flufigut-client.sh
diff options
context:
space:
mode:
Diffstat (limited to 'src/flufigut-client.sh')
-rwxr-xr-xsrc/flufigut-client.sh14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/flufigut-client.sh b/src/flufigut-client.sh
index e62a465..7cb0c54 100755
--- a/src/flufigut-client.sh
+++ b/src/flufigut-client.sh
@@ -64,8 +64,6 @@ if [ "install" = "$1" ]; then
fi
remove_instance() {
- type="$1"
- name="$2"
if [ "$1" = "worker" ]; then
sudo -u flumotion rm "$CONF_DIR/workers/$2.xml"
elif [ "$1" = "manager" ]; then
@@ -91,9 +89,8 @@ param=`echo $SSH_ORIGINAL_COMMAND | awk '{ print $2 }'`
case "$command" in
install)
- echo -n "install files from $param ... "
- cd $CONF_DIR
- sudo -u flumotion tar --strip-components=2 -xzf "$param"
+ echo -n "install files from '$param' ... "
+ sudo -u flumotion tar -C "$CONF_DIR" --strip-components=2 -xzf "$param"
rm "$param"
echo "done."
;;
@@ -106,6 +103,13 @@ case "$command" in
done
echo "ok."
;;
+ wipe)
+ echo -n "wiping files ... "
+ sudo -u flumotion rm "$CONF_DIR/workers/$param-"*.xml 2> /dev/null
+ sudo -u flumotion rm -rf "$CONF_DIR/managers/$param/" 2> /dev/null
+ sudo -u flumotion rm "$CONF_DIR/$param.passwd" 2> /dev/null
+ echo "done."
+ ;;
start)
echo -n "starting ... "
while read line; do