From 8435281809a32ea0f125224218cea9c69fd6903c Mon Sep 17 00:00:00 2001 From: Mohammed Naser Date: Sat, 9 Nov 2019 16:19:11 +0800 Subject: [PATCH] build-test-packages: add retries for git clones It's possible that GitHub might be having issues during a CI run which results in the clone failing making the entire job fail. Given that a failure in cloning can easily be retried with no consequences, let's do that to avoid failing the entire job. Change-Id: I8d1bad8d453c61ac113a0bab3529392cbffaf75a --- roles/build-test-packages/tasks/main.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/roles/build-test-packages/tasks/main.yml b/roles/build-test-packages/tasks/main.yml index 71fd7928e..b7a8c2045 100644 --- a/roles/build-test-packages/tasks/main.yml +++ b/roles/build-test-packages/tasks/main.yml @@ -132,6 +132,10 @@ repo: '{{ artg_rdoinfo_repo_url }}' dest: '{{ build_repo_dir }}/DLRN/rdoinfo' version: 'master' + register: _git_clone + until: _git_clone is success + retries: 3 + delay: 5 - name: Use local {{ ansible_distribution }} mirror if available shell: >