Commit 7e666e08 authored by Daniel Smith's avatar Daniel Smith

Merge pull request #24213 from mikedanese/max-time

add a timeout for a single retry in download-or-bust
parents d8532e07 8e8c55a3
...@@ -154,7 +154,7 @@ download-or-bust() { ...@@ -154,7 +154,7 @@ download-or-bust() {
for url in "${urls[@]}"; do for url in "${urls[@]}"; do
local file="${url##*/}" local file="${url##*/}"
rm -f "${file}" rm -f "${file}"
if ! curl -f --ipv4 -Lo "${file}" --connect-timeout 20 --retry 6 --retry-delay 10 "${url}"; then if ! curl -f --ipv4 -Lo "${file}" --connect-timeout 20 --max-time 80 --retry 6 --retry-delay 10 "${url}"; then
echo "== Failed to download ${url}. Retrying. ==" echo "== Failed to download ${url}. Retrying. =="
elif [[ -n "${hash}" ]] && ! validate-hash "${file}" "${hash}"; then elif [[ -n "${hash}" ]] && ! validate-hash "${file}" "${hash}"; then
echo "== Hash validation of ${url} failed. Retrying. ==" echo "== Hash validation of ${url} failed. Retrying. =="
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment