summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xleap-platform-test14
1 files changed, 6 insertions, 8 deletions
diff --git a/leap-platform-test b/leap-platform-test
index 3f76b4f..366132e 100755
--- a/leap-platform-test
+++ b/leap-platform-test
@@ -325,15 +325,13 @@ else
nodes=$nodelist
fi
-# check if another process is already running for given nodes
-for i in $nodes; do
- procs=`pgrep -fc "leap-platform-test.*$i"`
- if [ $procs -gt 1 ]; then
- echo "Another process is already running for node $i - exiting."
- exit 1
- fi
-done
+# check if another process is already running with same config file
+procs=`pgrep -fc "leap-platform-test.*-c.*$config"`
+if [ $procs -gt 1 ]; then
+ echo "Other process(es) found running for config $config - exiting."
+ exit 1
+fi
case $cmd in
add_nodes) add_nodes "$nodes";;