From cb0fc3000447b6305491fe24d28d4b8574e4acac Mon Sep 17 00:00:00 2001 From: Brenton Leanhardt Date: Mon, 28 Mar 2016 14:38:33 -0400 Subject: Use openshift.master.ha instead of duplicating the logic --- roles/openshift_master/tasks/systemd_units.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'roles/openshift_master/tasks/systemd_units.yml') diff --git a/roles/openshift_master/tasks/systemd_units.yml b/roles/openshift_master/tasks/systemd_units.yml index d4e5a60d2..1037890d1 100644 --- a/roles/openshift_master/tasks/systemd_units.yml +++ b/roles/openshift_master/tasks/systemd_units.yml @@ -18,7 +18,7 @@ template: src: "{{ ha_svc_template_path }}/atomic-openshift-master-{{ item }}.service.j2" dest: "{{ ha_svc_svc_dir }}/{{ openshift.common.service_type }}-master-{{ item }}.service" - when: openshift_master_ha | bool and openshift_master_cluster_method == "native" + when: openshift.master.ha is defined and openshift.master.ha | bool and openshift_master_cluster_method == "native" with_items: - api - controllers @@ -32,7 +32,7 @@ template: src: "{{ ha_svc_template_path }}/atomic-openshift-master-api.j2" dest: /etc/sysconfig/{{ openshift.common.service_type }}-master-api - when: openshift_master_ha | bool and openshift_master_cluster_method == "native" + when: openshift.master.ha is defined and openshift.master.ha | bool and openshift_master_cluster_method == "native" notify: - restart master api @@ -40,7 +40,7 @@ template: src: "{{ ha_svc_template_path }}/atomic-openshift-master-controllers.j2" dest: /etc/sysconfig/{{ openshift.common.service_type }}-master-controllers - when: openshift_master_ha | bool and openshift_master_cluster_method == "native" + when: openshift.master.ha is defined and openshift.master.ha | bool and openshift_master_cluster_method == "native" notify: - restart master controllers @@ -49,7 +49,7 @@ dest: "/etc/systemd/system/{{ openshift.common.service_type }}-master.service" src: docker/master.docker.service.j2 register: install_result - when: openshift.common.is_containerized | bool and not openshift_master_ha | bool + when: openshift.common.is_containerized | bool and openshift.master.ha is defined and not openshift.master.ha | bool - name: Create the master service env file template: -- cgit v1.2.1