Browse Source

remove svc creation and master config from base tasks in vsphere cloud provider

Davis Phillips 6 years ago
parent
commit
e9a017304d

+ 20 - 0
playbooks/openshift-master/private/additional_config.yml

@@ -40,6 +40,26 @@
   - role: flannel_register
     when: openshift_use_flannel | default(false) | bool
 
+- name: configure vsphere svc account
+  hosts: oo_first_master
+  tasks:
+  - import_role:
+      name: openshift_cloud_provider
+      tasks_from: vsphere-svc
+    when:
+    - openshift_cloudprovider_kind is defined
+    - openshift_cloudprovider_kind == 'vsphere'
+    - openshift_version | version_compare('3.9', '>=')
+
+- name: update vsphere provider master config
+  hosts: oo_masters_to_config
+  import_role:
+    name: openshift_cloud_provider
+    tasks_from: update-vsphere
+  when:
+  - openshift_cloudprovider_kind is defined
+  - openshift_cloudprovider_kind == 'vsphere'
+
 - name: Master Additional Install Checkpoint End
   hosts: all
   gather_facts: false

+ 0 - 10
roles/openshift_cloud_provider/tasks/vsphere.yml

@@ -9,13 +9,3 @@
   - openshift_cloudprovider_vsphere_host is defined
   - openshift_cloudprovider_vsphere_datacenter is defined
   - openshift_cloudprovider_vsphere_datastore is defined
-
-- name: Configure vsphere svc account
-  include_tasks: vsphere-svc.yml
-  when:
-  - openshift_version | version_compare('3.9', '>=')
-  - inventory_hostname == openshift_master_hosts[0]
-
-- name: Modify controller args
-  include_tasks: update-vsphere.yml
-  notify: restart master