From 01c3d7b4a8a640320acc17bb77d4b425c704c10e Mon Sep 17 00:00:00 2001 From: jimsihk <99048231+jimsihk@users.noreply.github.com> Date: Sun, 10 Mar 2024 15:05:47 +0800 Subject: [PATCH] Fix shutdown timeout command --- rootfs/bin/docker-entrypoint.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rootfs/bin/docker-entrypoint.sh b/rootfs/bin/docker-entrypoint.sh index e81b0b94b..94178568c 100755 --- a/rootfs/bin/docker-entrypoint.sh +++ b/rootfs/bin/docker-entrypoint.sh @@ -17,7 +17,7 @@ shutdown() { # kill any other processes still running in the container for _pid in $(ps -eo pid | grep -v PID | tr -d ' ' | grep -v '^1$' | head -n -6); do - timeout -t 5 /bin/sh -c "kill $_pid && wait $_pid || kill -9 $_pid" + timeout 5 /bin/sh -c "kill $_pid && wait $_pid || kill -9 $_pid" done exit } @@ -67,4 +67,4 @@ done trap shutdown SIGTERM SIGHUP SIGQUIT SIGINT wait $RUNSVDIR -shutdown \ No newline at end of file +shutdown