diff options
Diffstat (limited to 'playbooks/common/openshift-cluster/scaleup.yml')
-rw-r--r-- | playbooks/common/openshift-cluster/scaleup.yml | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/playbooks/common/openshift-cluster/scaleup.yml b/playbooks/common/openshift-cluster/scaleup.yml index e4b4564d8..2ba5bb8a2 100644 --- a/playbooks/common/openshift-cluster/scaleup.yml +++ b/playbooks/common/openshift-cluster/scaleup.yml @@ -21,26 +21,28 @@ - name: Update master count hosts: oo_masters:!oo_masters_to_config serial: 1 - vars: - openshift_master_count: "{{ groups.oo_masters | length }}" roles: - openshift_facts post_tasks: + - openshift_facts: + role: master + local_facts: + master_count: "{{ openshift_master_count | default(groups.oo_masters | length) }}" - name: Update master count lineinfile: dest: "{{ openshift.common.config_base}}/master/master-config.yaml" regexp: '^ masterCount:.*$' - line: " masterCount: {{ openshift_master_count }}" - register: master_config - - name: Restart master api - service: name={{ openshift.common.service_type }}-master-api state=restarted - when: master_config | changed - notify: Verify api server + line: " masterCount: {{ openshift.master.master_count }}" + notify: + - restart master api + - restart master controllers + handlers: + - name: restart master api + service: name={{ openshift.common.service_type }}-master-controllers state=restarted + notify: verify api server - name: restart master controllers service: name={{ openshift.common.service_type }}-master-controllers state=restarted - when: master_config | changed - handlers: - - name: Verify api server + - name: verify api server command: > curl -k --head --silent {{ openshift.master.api_url }} register: api_available_output |