Skip to content

Commit

Permalink
cherry pick pingcap#33610 to release-6.0
Browse files Browse the repository at this point in the history
Signed-off-by: ti-srebot <[email protected]>
  • Loading branch information
YuJuncen authored and ti-srebot committed Apr 1, 2022
1 parent 36a9810 commit ae42996
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion br/tests/br_s3/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,15 @@ start_s3() {
bin/minio server --address $S3_ENDPOINT "$TEST_DIR/$DB" &
s3_pid=$!
i=0
while ! curl -o /dev/null -v -s "http://$S3_ENDPOINT/"; do
status="$(curl -o /dev/null -v -s "http://$S3_ENDPOINT/" -w '%{http_code}' || true)"
while ! [ "$status" -gt 0 ] && [ "$status" -lt 500 ]; do
i=$(($i+1))
if [ $i -gt 30 ]; then
echo 'Failed to start minio'
exit 1
fi
sleep 2
status="$(curl -o /dev/null -v -s "http://$S3_ENDPOINT/" -w '%{http_code}' || true)"
done
}

Expand Down

0 comments on commit ae42996

Please sign in to comment.