Skip to content

Commit e4df23d

Browse files
matzfjuagargi
authored andcommitted
scion.sh: block for child processes at shutdown (scionproto#4445)
The `supervisorctl shutdown` command does not block for the supervisor or its child processes to terminate. This can occasionally lead to situations where SCION processes were still running after the `scion.sh stop` command returned. In the CI system, which immediately proceeds to bundle up the log files, this led to `tar` reporting an error that the log file was still being written to. Fixed by invoking `supervisorctl stop all`, which does block, to terminate all child processes before `shutdown`.
1 parent a16bdf7 commit e4df23d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scion.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,8 @@ stop_scion() {
113113
if is_docker_be; then
114114
./tools/quiet ./tools/dc down
115115
else
116-
./tools/quiet tools/supervisor.sh shutdown
116+
./tools/quiet tools/supervisor.sh stop all # blocks until child processes are stopped
117+
./tools/quiet tools/supervisor.sh shutdown # shutdown does not block, but as children are already stopped, actual shutdown will be prompt too.
117118
run_teardown
118119
fi
119120
}

0 commit comments

Comments
 (0)