]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
iscsigw: add retry/until
authorGuillaume Abrioux <gabrioux@redhat.com>
Wed, 19 Aug 2020 16:11:02 +0000 (18:11 +0200)
committerGuillaume Abrioux <gabrioux@redhat.com>
Thu, 20 Aug 2020 11:25:05 +0000 (13:25 +0200)
In order to avoid failures that could be fixed by simply
retrying.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
roles/ceph-iscsi-gw/tasks/non-container/prerequisites.yml

index d132cb98dc44191aa74a7436daea0fba14bbf1ed..2590803f4a20b7eff3e4ec1324811513151f638b 100644 (file)
@@ -34,6 +34,8 @@
             url: 'https://shaman.ceph.com/api/repos/{{ item }}/master/latest/{{ ansible_distribution | lower }}/{{ ansible_distribution_major_version }}/repo'
             dest: '/etc/yum.repos.d/{{ item }}-dev.repo'
             force: true
+          register: result
+          until: result is succeeded
           with_items: "{{ common_repos }}"
 
         - name: ceph-iscsi development repository
@@ -41,6 +43,8 @@
             url: 'https://shaman.ceph.com/api/repos/{{ item }}/master/latest/{{ ansible_distribution | lower }}/{{ ansible_distribution_major_version }}/repo'
             dest: '/etc/yum.repos.d/{{ item }}-dev.repo'
             force: true
+          register: result
+          until: result is succeeded
           with_items: '{{ iscsi_base }}'
           when: ceph_repository == 'dev'
 
@@ -49,6 +53,8 @@
             url: 'https://download.ceph.com/ceph-iscsi/{{ "3" if use_new_ceph_iscsi | bool else "2" }}/rpm/el{{ ansible_distribution_major_version }}/ceph-iscsi.repo'
             dest: /etc/yum.repos.d/ceph-iscsi.repo
             force: true
+          register: result
+          until: result is succeeded
           when: ceph_repository == 'community'
 
     - name: install ceph iscsi package