diff options
author | Magnus Ahltorp <map@kth.se> | 2017-02-07 16:29:46 +0100 |
---|---|---|
committer | Magnus Ahltorp <map@kth.se> | 2017-02-07 16:29:46 +0100 |
commit | 4108558e0ac7622776db69a283b83486647f8c65 (patch) | |
tree | bc7fc8c78ad048121eae859a91da26ae220106a0 /test/scripts/light-system-test-stop.sh | |
parent | 71cc72d3c5e977355ebb0aa8bcb065a08207ec2f (diff) |
Improve start and stop of Erlang nodesbetter-start-stop
Diffstat (limited to 'test/scripts/light-system-test-stop.sh')
-rwxr-xr-x | test/scripts/light-system-test-stop.sh | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/test/scripts/light-system-test-stop.sh b/test/scripts/light-system-test-stop.sh index 2265a34..a946079 100755 --- a/test/scripts/light-system-test-stop.sh +++ b/test/scripts/light-system-test-stop.sh @@ -7,14 +7,20 @@ top_srcdir=$(cd $(dirname $0)/../..; pwd) . ${top_srcdir}/test/scripts/testutils.sh +nodetypes="$@" + stop_node() { node=$1 ${top_srcdir}/tools/to_catlfish.py to_erl nodes/${node}/ "init:stop()" } -for nodegroup in $FRONTENDNODES $MERGEPRIMARYNODE $STORAGENODES $MERGESECONDARYNODES $SIGNINGNODES; do - for node in $nodegroup; do - echo "starting $node" - stop_node $(echo $node | tr ':' ' ') - done +nodes= +for nodetype in $nodetypes; do + nodetype_uc=$(echo $nodetype | tr a-z A-Z) + nodes="$nodes $(eval echo \$${nodetype_uc}NODES)" +done + +for node in $nodes; do + echo "stopping $node" + stop_node $(echo $node | tr ':' ' ') done |