From aac62b2cc7bf54cf3fc3fb1581d916d267f4e6db Mon Sep 17 00:00:00 2001 From: Zack Cerza Date: Wed, 27 Dec 2023 11:22:39 -0700 Subject: [PATCH] repo_utils.fetch_repo: Use less retries If a particular branch cannot successfully bootstrap, it can cause an accidental DoS. Signed-off-by: Zack Cerza --- teuthology/repo_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/teuthology/repo_utils.py b/teuthology/repo_utils.py index ca0785bfdc..6ab0747ade 100644 --- a/teuthology/repo_utils.py +++ b/teuthology/repo_utils.py @@ -358,7 +358,7 @@ def fetch_repo(url, branch, commit=None, bootstrap=None, lock=True): # only let one worker create/update the checkout at a time lock_path = dest_path.rstrip('/') + '.lock' with FileLock(lock_path, noop=not lock): - with safe_while(sleep=10, tries=60) as proceed: + with safe_while(sleep=10, tries=6) as proceed: try: while proceed(): try: -- 2.39.5