We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents c4381c5 + 5c3e968 commit 66847bbCopy full SHA for 66847bb
hack/util.sh
@@ -40,27 +40,6 @@ function ensure_iptables_or_die() {
40
}
41
readonly -f ensure_iptables_or_die
42
43
-# tryuntil loops, retrying an action until it succeeds or times out after 90 seconds.
44
-function tryuntil() {
45
- timeout=$(($(date +%s) + 90))
46
- echo "++ Retrying until success or timeout: ${@}"
47
- while [ 1 ]; do
48
- if eval "${@}" >/dev/null 2>&1; then
49
- return 0
50
- fi
51
- if [[ $(date +%s) -gt $timeout ]]; then
52
- # run it one more time so we can display the output
53
- # for debugging, since above we /dev/null the output
54
- if eval "${@}"; then
55
56
57
- echo "++ timed out"
58
- return 1
59
60
- done
61
-}
62
-readonly -f tryuntil
63
-
64
# wait_for_command executes a command and waits for it to
65
# complete or times out after max_wait.
66
#
0 commit comments