Browse Source

Merge pull request #388 from blesson-james/devel

Issue #387: Added retries for helm installation tasks and fixed other minor bugs
Lucas A. Wilson 3 years ago
parent
commit
3632050488

+ 2 - 2
control_plane/roles/control_plane_device/tasks/mngmnt_network_container_image.yml

@@ -29,8 +29,8 @@
 - name: Update omnia project path in k8s_mngmnt_network.yml
   replace:
     path: "{{ role_path }}/files/k8s_mngmnt_network.yml"
-    regexp: 'path: /root/omnia'
-    replace: "path: {{ role_path.split('control_plane')[0] }}"
+    regexp: '        - name: omnia-storage\n          hostPath:\n            path:.*'
+    replace: "        - name: omnia-storage\n          hostPath:\n            path: {{ role_path.split('control_plane')[0] }}"
 
 - name: Deploy mngmnt_network pod
   command: "kubectl apply -f {{ role_path }}/files/k8s_mngmnt_network.yml"

+ 2 - 2
control_plane/roles/control_plane_ib/tasks/infiniband_container_image.yml

@@ -29,8 +29,8 @@
 - name: Update omnia project path in k8s_infiniband.yml
   replace:
     path: "{{ role_path }}/files/k8s_infiniband.yml"
-    regexp: 'path: /root/omnia'
-    replace: "path: {{ role_path.split('control_plane')[0] }}"
+    regexp: '        - name: omnia-storage\n          hostPath:\n            path:.*'
+    replace: "        - name: omnia-storage\n          hostPath:\n            path: {{ role_path.split('control_plane')[0] }}"
 
 - name: Deploy infiniband pod
   command: "kubectl apply -f {{ role_path }}/files/k8s_infiniband.yml"

+ 3 - 0
control_plane/roles/control_plane_k8s/tasks/k8s_helm.yml

@@ -31,6 +31,9 @@
 - name: Install helm
   command: "/bin/bash {{ helm_installer_file_dest }}"
   changed_when: true
+  register: install_helm_result
+  until: install_helm_result is not failed
+  retries: 20
 
 - name: Helm - add stable repo
   command: "helm repo add stable '{{ helm_stable_repo_url }}'"

+ 2 - 2
control_plane/roles/provision_cobbler/tasks/cobbler_image.yml

@@ -29,8 +29,8 @@
 - name: Update omnia project path in k8s_cobbler.yml
   replace:
     path: "{{ role_path }}/files/k8s_cobbler.yml"
-    regexp: 'path: /root/omnia'
-    replace: "path: {{ role_path.split('control_plane')[0] }}"
+    regexp: '        - name: omnia-storage\n          hostPath:\n            path:.*'
+    replace: "        - name: omnia-storage\n          hostPath:\n            path: {{ role_path.split('control_plane')[0] }}"
 
 - name: Deploy cobbler pod
   command: "kubectl apply -f {{ role_path }}/files/k8s_cobbler.yml"