File tree Expand file tree Collapse file tree 7 files changed +18
-18
lines changed
Expand file tree Collapse file tree 7 files changed +18
-18
lines changed Original file line number Diff line number Diff line change @@ -199,7 +199,7 @@ elif [ "$1" = "step2" ]; then
199199 # It is necessary to restart supervisord with new environment.
200200 " $STATE_CLUSTER /supervisorctl" stop all
201201 sleep 5
202- " $STATE_CLUSTER /supervisord_stop "
202+ " $STATE_CLUSTER /stop-cluster "
203203 sleep 3
204204 " $STATE_CLUSTER /supervisord_start" || exit 6
205205 sleep 5
Original file line number Diff line number Diff line change @@ -6,6 +6,6 @@ stop_instances() {
66 local workdir=" ${1:? } "
77 for sc in " $workdir " /state-cluster* ; do
88 [ -d " $sc " ] || continue
9- " $sc /supervisord_stop " 2> /dev/null || :
9+ " $sc /stop-cluster " 2> /dev/null || :
1010 done
1111}
Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ DELEG_SUPPLY="$((POOL_PLEDGE * NUM_POOLS + DELEG_MAGIC_VALUE))"
5555NONDELEG_SUPPLY=" $(( (MAX_SUPPLY - DELEG_SUPPLY) * 8 / 10 )) "
5656
5757if [ -f " ${STATE_CLUSTER} /supervisord.pid" ]; then
58- echo " Cluster already running. Please run \` ${SCRIPT_DIR } /stop-cluster\` first!" >&2
58+ echo " Cluster already running. Please run \` ${STATE_CLUSTER } /stop-cluster\` first!" >&2
5959 exit 1
6060fi
6161
@@ -534,7 +534,7 @@ cd "\${SCRIPT_DIR}/.."
534534supervisord --config "\$ {SCRIPT_DIR}/supervisor.conf"
535535EoF
536536
537- cat > " ${STATE_CLUSTER} /supervisord_stop " << EoF
537+ cat > " ${STATE_CLUSTER} /stop-cluster " << EoF
538538#!/usr/bin/env bash
539539
540540set -uo pipefail
@@ -567,7 +567,7 @@ rm -f "\$PID_FILE"
567567echo "Cluster terminated!"
568568EoF
569569
570- chmod u+x " $STATE_CLUSTER " /{supervisorctl* ,supervisord_* }
570+ chmod u+x " $STATE_CLUSTER " /{supervisorctl* ,supervisord_* ,stop-cluster }
571571
572572if [ -n " ${DRY_RUN:- " " } " ]; then
573573 echo " Dry run, not starting cluster"
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ if [ "$POOL_COST" -eq 0 ]; then
4949fi
5050
5151if [ -f " ${STATE_CLUSTER} /supervisord.pid" ]; then
52- echo " Cluster already running. Please run \` ${SCRIPT_DIR } /stop-cluster\` first!" >&2
52+ echo " Cluster already running. Please run \` ${STATE_CLUSTER } /stop-cluster\` first!" >&2
5353 exit 1
5454fi
5555
@@ -612,7 +612,7 @@ cd "\${SCRIPT_DIR}/.."
612612supervisord --config "\$ {SCRIPT_DIR}/supervisor.conf"
613613EoF
614614
615- cat > " ${STATE_CLUSTER} /supervisord_stop " << EoF
615+ cat > " ${STATE_CLUSTER} /stop-cluster " << EoF
616616#!/usr/bin/env bash
617617
618618set -uo pipefail
@@ -645,7 +645,7 @@ rm -f "\$PID_FILE"
645645echo "Cluster terminated!"
646646EoF
647647
648- chmod u+x " $STATE_CLUSTER " /{supervisorctl* ,supervisord_* }
648+ chmod u+x " $STATE_CLUSTER " /{supervisorctl* ,supervisord_* ,stop-cluster }
649649
650650if [ -n " ${DRY_RUN:- " " } " ]; then
651651 echo " Dry run, not starting cluster"
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ if [[ "$SOCKET_PATH" != *"/state-cluster${INSTANCE_NUM}/"* ]]; then
1818fi
1919
2020if [ -f " $STATE_CLUSTER /supervisord.pid" ]; then
21- echo " Cluster already running. Please run \` $SCRIPT_DIR /stop-cluster\` first!" >&2
21+ echo " Cluster already running. Please run \` ${STATE_CLUSTER} /stop-cluster\` first!" >&2
2222 exit 1
2323fi
2424
@@ -134,7 +134,7 @@ cd "\$SCRIPT_DIR/.."
134134supervisord --config "\$ SCRIPT_DIR/supervisor.conf"
135135EoF
136136
137- cat > " $STATE_CLUSTER /supervisord_stop " << EoF
137+ cat > " $STATE_CLUSTER /stop-cluster " << EoF
138138#!/usr/bin/env bash
139139
140140set -uo pipefail
@@ -167,7 +167,7 @@ rm -f "\$PID_FILE"
167167echo "Cluster terminated!"
168168EoF
169169
170- chmod u+x " $STATE_CLUSTER " /{supervisorctl* ,supervisord_* }
170+ chmod u+x " $STATE_CLUSTER " /{supervisorctl* ,supervisord_* ,stop-cluster }
171171
172172# copy db
173173cp -r " $TESTNET_DIR /relay1-db" " $STATE_CLUSTER /db-relay1"
@@ -228,4 +228,4 @@ faucet_init_balance="$(get_address_balance \
228228 --address " $( < " $STATE_CLUSTER /shelley/faucet.addr" ) " ) "
229229echo " Faucet initial balance: $faucet_init_balance " >> " $START_CLUSTER_LOG "
230230
231- echo " Cluster started. Run \` $SCRIPT_DIR /stop-cluster \` to stop "
231+ echo " Cluster started"
Original file line number Diff line number Diff line change 11"""Functionality for cluster scripts (starting and stopping clusters).
22
3- * copying scripts and their configuration, so it can be atered by tests
3+ * copying scripts and their configuration, so it can be altered by tests
44* setup of scripts and their configuration for starting of multiple cluster instances
55"""
66
1818from cardano_node_tests .utils import helpers
1919
2020LOCAL_HOSTNAME = "node.local.gd"
21- STOP_SCRIPT = "supervisord_stop "
21+ STOP_SCRIPT = "stop-cluster "
2222
2323
2424@dataclasses .dataclass (frozen = True , order = True )
Original file line number Diff line number Diff line change @@ -11,13 +11,13 @@ if [ -z "${DEV_CLUSTER_RUNNING:-}" ]; then
1111 exit 1
1212fi
1313
14- # check if "supervisord_stop " file exists in STATE_CLUSTER dir
15- if [ ! -f " ${STATE_CLUSTER} /supervisord_stop " ]; then
16- echo " Cannot find '${STATE_CLUSTER} /supervisord_stop ', exiting."
14+ # check if "stop-cluster " file exists in STATE_CLUSTER dir
15+ if [ ! -f " ${STATE_CLUSTER} /stop-cluster " ]; then
16+ echo " Cannot find '${STATE_CLUSTER} /stop-cluster ', exiting."
1717 exit 1
1818fi
1919
20- " $STATE_CLUSTER /supervisord_stop "
20+ " $STATE_CLUSTER /stop-cluster "
2121sleep 2
2222
2323" $STATE_CLUSTER /supervisord_start"
You can’t perform that action at this time.
0 commit comments