Skip to content

Commit d49345a

Browse files
committed
update gettign STATUSCODE TO support redirect as well
1 parent 77fe227 commit d49345a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

helm/templates/loadgenerator.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ spec:
7474
RETRY_INTERVAL=10
7575
for i in $(seq 1 $MAX_RETRIES); do
7676
echo "Attempt $i: Pinging frontend: ${FRONTEND_ADDR}..."
77-
STATUSCODE=$(wget --server-response http://${FRONTEND_ADDR} 2>&1 | awk '/^ HTTP/{print $2}')
77+
STATUSCODE=$(wget --server-response http://${FRONTEND_ADDR} 2>&1 | awk '/^ HTTP/{code=$2} END{print code}')
7878
if [ $STATUSCODE -eq 200 ]; then
7979
echo "Frontend is reachable."
8080
exit 0

0 commit comments

Comments
 (0)