diff options
author | Scott Dodson <sdodson@redhat.com> | 2017-06-23 09:16:52 -0400 |
---|---|---|
committer | Scott Dodson <sdodson@redhat.com> | 2017-06-23 09:19:23 -0400 |
commit | c2c51673295cc84631a101ac236535e5d14769d5 (patch) | |
tree | 6347114085f46a2b1fda817e43c3ff94015ac83c /playbooks/common/openshift-master/config.yml | |
parent | 6c0760068922d06ca161d833c1e9dc442ab8960e (diff) | |
download | openshift-c2c51673295cc84631a101ac236535e5d14769d5.tar.gz openshift-c2c51673295cc84631a101ac236535e5d14769d5.tar.bz2 openshift-c2c51673295cc84631a101ac236535e5d14769d5.tar.xz openshift-c2c51673295cc84631a101ac236535e5d14769d5.zip |
Set clean install and etcd storage on first master to fix scaleup
Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1464011
Diffstat (limited to 'playbooks/common/openshift-master/config.yml')
-rw-r--r-- | playbooks/common/openshift-master/config.yml | 39 |
1 files changed, 19 insertions, 20 deletions
diff --git a/playbooks/common/openshift-master/config.yml b/playbooks/common/openshift-master/config.yml index 70108fb7a..7d3a371e3 100644 --- a/playbooks/common/openshift-master/config.yml +++ b/playbooks/common/openshift-master/config.yml @@ -20,25 +20,6 @@ - node - .config_managed - - name: Check for existing configuration - stat: - path: /etc/origin/master/master-config.yaml - register: master_config_stat - - - name: Set clean install fact - set_fact: - l_clean_install: "{{ not master_config_stat.stat.exists | bool }}" - - - name: Determine if etcd3 storage is in use - command: grep -Pzo "storage-backend:\n.*etcd3" /etc/origin/master/master-config.yaml -q - register: etcd3_grep - failed_when: false - changed_when: false - - - name: Set etcd3 fact - set_fact: - l_etcd3_enabled: "{{ etcd3_grep.rc == 0 | bool }}" - - set_fact: openshift_master_pod_eviction_timeout: "{{ lookup('oo_option', 'openshift_master_pod_eviction_timeout') | default(none, true) }}" when: openshift_master_pod_eviction_timeout is not defined @@ -88,7 +69,7 @@ ha: "{{ openshift_master_ha | default(groups.oo_masters | length > 1) }}" master_count: "{{ openshift_master_count | default(groups.oo_masters | length) }}" -- name: Determine if session secrets must be generated +- name: Inspect state of first master session secrets and config hosts: oo_first_master roles: - role: openshift_facts @@ -98,6 +79,24 @@ local_facts: session_auth_secrets: "{{ openshift_master_session_auth_secrets | default(openshift.master.session_auth_secrets | default(None)) }}" session_encryption_secrets: "{{ openshift_master_session_encryption_secrets | default(openshift.master.session_encryption_secrets | default(None)) }}" + - name: Check for existing configuration + stat: + path: /etc/origin/master/master-config.yaml + register: master_config_stat + + - name: Set clean install fact + set_fact: + l_clean_install: "{{ not master_config_stat.stat.exists | bool }}" + + - name: Determine if etcd3 storage is in use + command: grep -Pzo "storage-backend:\n.*etcd3" /etc/origin/master/master-config.yaml -q + register: etcd3_grep + failed_when: false + changed_when: false + + - name: Set etcd3 fact + set_fact: + l_etcd3_enabled: "{{ etcd3_grep.rc == 0 | bool }}" - name: Generate master session secrets hosts: oo_first_master |