chore: add retries to openstack resources
diff --git a/roles/glance/tasks/main.yml b/roles/glance/tasks/main.yml
index b9c3bfd..92b9f14 100644
--- a/roles/glance/tasks/main.yml
+++ b/roles/glance/tasks/main.yml
@@ -91,3 +91,9 @@
ramdisk: "{{ item.ramdisk | default(omit) }}"
is_public: "{{ item.is_public | default(omit) }}"
loop: "{{ glance_images }}"
+ # NOTE(mnaser): This often fails since the SSL certificates are not
+ # ready yet. We need to wait for them to be ready.
+ retries: 60
+ delay: 5
+ register: _result
+ until: _result is not failed
diff --git a/roles/magnum/tasks/main.yml b/roles/magnum/tasks/main.yml
index f22a502..92b0dba 100644
--- a/roles/magnum/tasks/main.yml
+++ b/roles/magnum/tasks/main.yml
@@ -413,3 +413,9 @@
properties:
os_distro: ubuntu-focal
loop: "{{ magnum_images }}"
+ # NOTE(mnaser): This often fails since the SSL certificates are not
+ # ready yet. We need to wait for them to be ready.
+ retries: 60
+ delay: 5
+ register: _result
+ until: _result is not failed
diff --git a/roles/neutron/tasks/main.yml b/roles/neutron/tasks/main.yml
index b2a42f0..2b53912 100644
--- a/roles/neutron/tasks/main.yml
+++ b/roles/neutron/tasks/main.yml
@@ -82,6 +82,12 @@
provider_physical_network: "{{ item.provider_physical_network | default(omit) }}"
provider_segmentation_id: "{{ item.provider_segmentation_id | default(omit) }}"
loop: "{{ neutron_networks }}"
+ # NOTE(mnaser): This often fails since the SSL certificates are not
+ # ready yet. We need to wait for them to be ready.
+ retries: 60
+ delay: 5
+ register: _result
+ until: _result is not failed
- name: Create subnets
openstack.cloud.subnet:
@@ -103,3 +109,9 @@
with_subelements:
- "{{ neutron_networks }}"
- subnets
+ # NOTE(mnaser): This often fails since the SSL certificates are not
+ # ready yet. We need to wait for them to be ready.
+ retries: 60
+ delay: 5
+ register: _result
+ until: _result is not failed