summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorDaniel Baumann <mail@daniel-baumann.ch>2016-04-21 17:48:13 +0000
committerDaniel Baumann <mail@daniel-baumann.ch>2016-05-06 12:05:31 +0000
commitba34645a988c4c5daf702050ab9bb2e9b630b44d (patch)
treee0d5c6db7579b56308f4d092952e403becd984a5 /lib
parentAdding upstream version 20160401. (diff)
downloadopen-infrastructure-compute-tools-ba34645a988c4c5daf702050ab9bb2e9b630b44d.tar.xz
open-infrastructure-compute-tools-ba34645a988c4c5daf702050ab9bb2e9b630b44d.zip
Adding upstream version 20160415.upstream/20160415
Signed-off-by: Daniel Baumann <mail@daniel-baumann.ch>
Diffstat (limited to 'lib')
-rwxr-xr-xlib/container/list2
-rwxr-xr-xlib/container/stop12
2 files changed, 7 insertions, 7 deletions
diff --git a/lib/container/list b/lib/container/list
index 374942c..110e6ea 100755
--- a/lib/container/list
+++ b/lib/container/list
@@ -34,7 +34,7 @@ then
fi
# Run
-CONTAINERS="$(cd "${MACHINES}" && find -maxdepth 1 -type d -printf '%P\n' | sort)"
+CONTAINERS="$(cd "${MACHINES}" && find -maxdepth 1 -type d -and -not -name 'lost+found' -printf '%P\n' | sort)"
echo RUNNING
diff --git a/lib/container/stop b/lib/container/stop
index a11c155..cd3de10 100755
--- a/lib/container/stop
+++ b/lib/container/stop
@@ -24,8 +24,8 @@ MACHINES="/var/lib/machines"
Parameters ()
{
- LONG_OPTIONS="name:,kill"
- OPTIONS="n:,k"
+ LONG_OPTIONS="name:,force"
+ OPTIONS="n:,f"
PARAMETERS="$(getopt --longoptions ${LONG_OPTIONS} --name=${COMMAND} --options ${OPTIONS} --shell sh -- ${@})"
@@ -45,8 +45,8 @@ Parameters ()
shift 2
;;
- -k|--kill)
- KILL="true"
+ -f|--force)
+ FORCE="true"
;;
--)
@@ -64,7 +64,7 @@ Parameters ()
Usage ()
{
- echo "Usage: container ${COMMAND} -n|--name NAME [-k|--kill]" >&2
+ echo "Usage: container ${COMMAND} -n|--name NAME [-f|--force]" >&2
exit 1
}
@@ -93,7 +93,7 @@ case "${STATE}" in
;;
esac
-case "${KILL}" in
+case "${FORCE}" in
true)
MODE="terminate"
;;