Allow to keep the host header through a setting
Signed-off-by: Patrick Uiterwijk <puiterwijk@redhat.com>
This commit is contained in:
parent
7f5bfecaa7
commit
c0b7382df2
4 changed files with 8 additions and 0 deletions
|
@ -455,6 +455,7 @@
|
||||||
destname: qa-stg-phab
|
destname: qa-stg-phab
|
||||||
# Talk directly to the app server, not haproxy
|
# Talk directly to the app server, not haproxy
|
||||||
proxyurl: http://phab.qa-stg01.qa.fedoraproject.org
|
proxyurl: http://phab.qa-stg01.qa.fedoraproject.org
|
||||||
|
keephost: true
|
||||||
when: env == "staging"
|
when: env == "staging"
|
||||||
|
|
||||||
- role: httpd/reverseproxy
|
- role: httpd/reverseproxy
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
# - remotepath..
|
# - remotepath..
|
||||||
# - proxyurl
|
# - proxyurl
|
||||||
# - rewrite
|
# - rewrite
|
||||||
|
# - keephost
|
||||||
|
|
||||||
- name: Copy in ProxyPassReverse for {{destname}} ({{website}}{{remotepath}})
|
- name: Copy in ProxyPassReverse for {{destname}} ({{website}}{{remotepath}})
|
||||||
template: >
|
template: >
|
||||||
|
|
|
@ -9,5 +9,10 @@ RequestHeader set X-Scheme https early
|
||||||
RequestHeader set X-Forwarded-Proto https early
|
RequestHeader set X-Forwarded-Proto https early
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
{% if keephost %}
|
||||||
|
ProxyPreserveHost On
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
ProxyPass {{ localpath }} {{ proxyurl }}{{remotepath}}
|
ProxyPass {{ localpath }} {{ proxyurl }}{{remotepath}}
|
||||||
ProxyPassReverse {{ localpath }} {{ proxyurl }}{{remotepath}}
|
ProxyPassReverse {{ localpath }} {{ proxyurl }}{{remotepath}}
|
||||||
|
|
|
@ -3,3 +3,4 @@ localpath: /
|
||||||
destname: reversepassproxy
|
destname: reversepassproxy
|
||||||
rewrite: false
|
rewrite: false
|
||||||
header_scheme: false
|
header_scheme: false
|
||||||
|
keephost: false
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue