proxies / reverseproxy: try just always setting balancer_members and dropping the set facts
Signed-off-by: Kevin Fenzi <kevin@scrye.com>
This commit is contained in:
parent
7e90378b30
commit
42bc4ea41a
2 changed files with 13 additions and 40 deletions
|
@ -182,6 +182,7 @@
|
||||||
website: "accounts{{ env_suffix }}.fedoraproject.org"
|
website: "accounts{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: noggin
|
destname: noggin
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
ocp4: true
|
ocp4: true
|
||||||
|
@ -192,6 +193,7 @@
|
||||||
website: "fasjson{{ env_suffix }}.fedoraproject.org"
|
website: "fasjson{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: fasjson
|
destname: fasjson
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
ocp4: true
|
ocp4: true
|
||||||
|
@ -296,6 +298,7 @@
|
||||||
website: qa.fedoraproject.org
|
website: qa.fedoraproject.org
|
||||||
destname: blockerbugs
|
destname: blockerbugs
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
ocp4: true
|
ocp4: true
|
||||||
|
@ -308,6 +311,7 @@
|
||||||
website: qa.fedoraproject.org
|
website: qa.fedoraproject.org
|
||||||
destname: blockerbugs
|
destname: blockerbugs
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
ocp4: true
|
ocp4: true
|
||||||
|
@ -328,6 +332,7 @@
|
||||||
website: bodhi.fedoraproject.org
|
website: bodhi.fedoraproject.org
|
||||||
destname: bodhi
|
destname: bodhi
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
ocp4: true
|
ocp4: true
|
||||||
|
@ -352,6 +357,7 @@
|
||||||
website: "updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
@ -363,6 +369,7 @@
|
||||||
website: "status.updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "status.updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
@ -374,6 +381,7 @@
|
||||||
website: "raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
@ -385,6 +393,7 @@
|
||||||
website: "status.raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "status.raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
@ -396,6 +405,7 @@
|
||||||
website: "updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
@ -407,6 +417,7 @@
|
||||||
website: "status.updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "status.updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
@ -418,6 +429,7 @@
|
||||||
website: "raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
@ -429,6 +441,7 @@
|
||||||
website: "status.raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
website: "status.raw-updates.coreos{{ env_suffix }}.fedoraproject.org"
|
||||||
destname: cincinnati
|
destname: cincinnati
|
||||||
balancer_name: apps-ocp
|
balancer_name: apps-ocp
|
||||||
|
balancer_members: "{{ (env == 'staging')|ternary(ocp_nodes_stg, ocp_nodes) }}"
|
||||||
ocp4: true
|
ocp4: true
|
||||||
targettype: openshift
|
targettype: openshift
|
||||||
keephost: true
|
keephost: true
|
||||||
|
|
|
@ -7,42 +7,6 @@
|
||||||
# - keephost
|
# - keephost
|
||||||
# - proxyopts
|
# - proxyopts
|
||||||
|
|
||||||
- name: Set OpenShift information if not preconfigured (prod)
|
|
||||||
set_fact:
|
|
||||||
balancer_members: "{{ openshift_nodes }}"
|
|
||||||
when: 'targettype == "openshift" and balancer_members is not defined and env != "staging" '
|
|
||||||
tags:
|
|
||||||
- httpd
|
|
||||||
- httpd/reverseproxy
|
|
||||||
- httpd/reversepassproxy
|
|
||||||
|
|
||||||
- name: Set OpenShift4 information if not preconfigured (prod)
|
|
||||||
set_fact:
|
|
||||||
balancer_members: "{{ ocp_nodes }}"
|
|
||||||
when: 'targettype == "openshift" and ocp4|bool and balancer_members is not defined and env != "staging" '
|
|
||||||
tags:
|
|
||||||
- httpd
|
|
||||||
- httpd/reverseproxy
|
|
||||||
- httpd/reversepassproxy
|
|
||||||
|
|
||||||
- name: Set OpenShift information if not preconfigured (stg)
|
|
||||||
set_fact:
|
|
||||||
balancer_members: "{{ openshift_nodes_stg }}"
|
|
||||||
when: 'targettype == "openshift" and balancer_members is not defined and env == "staging" '
|
|
||||||
tags:
|
|
||||||
- httpd
|
|
||||||
- httpd/reverseproxy
|
|
||||||
- httpd/reversepassproxy
|
|
||||||
|
|
||||||
- name: Set OpenShift4 information if not preconfigured (stg)
|
|
||||||
set_fact:
|
|
||||||
balancer_members: "{{ ocp_nodes_stg }}"
|
|
||||||
when: 'targettype == "openshift" and ocp4|bool and balancer_members is not defined and env == "staging" '
|
|
||||||
tags:
|
|
||||||
- httpd
|
|
||||||
- httpd/reverseproxy
|
|
||||||
- httpd/reversepassproxy
|
|
||||||
|
|
||||||
- name: Copy in ProxyPassReverse for {{destname}} ({{website}}{{remotepath}})
|
- name: Copy in ProxyPassReverse for {{destname}} ({{website}}{{remotepath}})
|
||||||
template: >
|
template: >
|
||||||
src={{item}}
|
src={{item}}
|
||||||
|
@ -59,7 +23,3 @@
|
||||||
- httpd
|
- httpd
|
||||||
- httpd/reverseproxy
|
- httpd/reverseproxy
|
||||||
- httpd/reversepassproxy
|
- httpd/reversepassproxy
|
||||||
|
|
||||||
- name: clear balancer_members
|
|
||||||
set_fact:
|
|
||||||
balancer_members: !!null
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue