aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2016-09-28 06:45:45 +0000
committerGerrit Code Review <review@openstack.org>2016-09-28 06:45:45 +0000
commit974bffae1ead52f12fa61609455a15f1e64c3012 (patch)
tree77ae9211c419877e0d0b83546a54bb264f4991fa
parent206edae28d855a933610727db4cdc54a43dc827d (diff)
parentbcf7afb801bd34369a67f361dd1148692d6da440 (diff)
downloadkolla-974bffae1ead52f12fa61609455a15f1e64c3012.tar.gz
kolla-974bffae1ead52f12fa61609455a15f1e64c3012.zip
Merge "add congress api to haproxy"
-rw-r--r--ansible/roles/haproxy/templates/haproxy.cfg.j219
1 files changed, 19 insertions, 0 deletions
diff --git a/ansible/roles/haproxy/templates/haproxy.cfg.j2 b/ansible/roles/haproxy/templates/haproxy.cfg.j2
index a0594e11e..959e0da35 100644
--- a/ansible/roles/haproxy/templates/haproxy.cfg.j2
+++ b/ansible/roles/haproxy/templates/haproxy.cfg.j2
@@ -533,6 +533,25 @@ listen aodh_api_external
{% endif %}
{% endif %}
+{% if enable_congress | bool %}
+listen congress_api
+ bind {{ kolla_internal_vip_address }}:{{ congress_api_port }}
+ http-request del-header X-Forwarded-Proto
+{% for host in groups['congress-api'] %}
+ server {{ hostvars[host]['ansible_hostname'] }} {{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}:{{ congress_api_port }} check inter 2000 rise 2 fall 5
+{% endfor %}
+{% if haproxy_enable_external_vip | bool %}
+
+listen congress_api_external
+ bind {{ kolla_external_vip_address }}:{{ congress_api_port }} {{ tls_bind_info }}
+ http-request del-header X-Forwarded-Proto
+ http-request set-header X-Forwarded-Proto https if { ssl_fc }
+{% for host in groups['congress-api'] %}
+ server {{ hostvars[host]['ansible_hostname'] }} {{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}:{{ congress_api_port }} check inter 2000 rise 2 fall 5
+{% endfor %}
+{% endif %}
+{% endif %}
+
# (NOTE): This defaults section deletes forwardfor as recomended by:
# https://marc.info/?l=haproxy&m=141684110710132&w=1