From 9165f589250827ccaf048b6b20e1a34ac64817e5 Mon Sep 17 00:00:00 2001 From: Thomas Carmet <8408330+tcarmet@users.noreply.github.com> Date: Thu, 27 Jun 2024 08:57:53 +0000 Subject: [PATCH] PTFE-1834 fix lifecycle prestop failures --- stop.sh | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/stop.sh b/stop.sh index fce017c..b4856a3 100755 --- a/stop.sh +++ b/stop.sh @@ -7,7 +7,7 @@ echo "Stopping nginx..." sleep 5 # retrieve nginx status and check if there's any active connection -ACTIVE_CONNECTION="" +ACTIVE_CONNECTION="0" while [ ${ACTIVE_CONNECTION} != "1" ]; do ACTIVE_CONNECTION=$(curl -s http://localhost/nginx_status | grep 'Active connections' | awk '{print $3}') @@ -17,8 +17,3 @@ done PID=$(cat /run/nginx.pid) nginx -s quit - -echo "Waiting for nginx PID: ${PID} to stop..." -while [ -d /proc/$PID ]; do - sleep 0.1 -done