From 6799ce2162c9ea3d8243b57581d154c7edfe808f Mon Sep 17 00:00:00 2001 From: alesapin Date: Wed, 15 Dec 2021 18:46:40 +0300 Subject: [PATCH] Add retries to curl --- docker/test/performance-comparison/entrypoint.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/test/performance-comparison/entrypoint.sh b/docker/test/performance-comparison/entrypoint.sh index 047c64406c3..6d4f1222432 100755 --- a/docker/test/performance-comparison/entrypoint.sh +++ b/docker/test/performance-comparison/entrypoint.sh @@ -55,7 +55,7 @@ function find_reference_sha ) for path in "${urls_to_try[@]}" do - if curl --fail --head "$path" + if curl --fail --retry 5 --retry-delay 1 --retry-max-time 15 --head "$path" then found="$path" break @@ -76,7 +76,7 @@ chmod 777 workspace output cd workspace # Download the package for the version we are going to test. -if curl --fail --head "$S3_URL/$PR_TO_TEST/$SHA_TO_TEST$COMMON_BUILD_PREFIX/performance/performance.tgz" +if curl --fail --retry 5 --retry-delay 1 --retry-max-time 15 --head "$S3_URL/$PR_TO_TEST/$SHA_TO_TEST$COMMON_BUILD_PREFIX/performance/performance.tgz" then right_path="$S3_URL/$PR_TO_TEST/$SHA_TO_TEST$COMMON_BUILD_PREFIX/performance/performance.tgz" fi