aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuan Antonio Osorio Robles <jaosorior@redhat.com>2016-09-12 09:37:56 +0300
committerJuan Antonio Osorio Robles <jaosorior@redhat.com>2016-09-12 09:38:51 +0300
commitad5182f6323065eb45f9168db9e9e52b801f625b (patch)
tree0adb9b8ec600b46f47ce3d87c5944122ca44906c
parentcbd84e7e52d5751f74bebbff866c784809df6bde (diff)
Enable X-Forwarded-Proto for manila
This is necessary so the middleware in manila can set the protocol correctly in case we're terminating SSL in HAProxy. Depends-On: Ice78b0abceb6a956bb8c1dc6212ee1b56b62b43f Change-Id: Iedaabaf1379466c22e3b9bb2307e940459d26de7
-rw-r--r--manifests/haproxy.pp5
1 files changed, 5 insertions, 0 deletions
diff --git a/manifests/haproxy.pp b/manifests/haproxy.pp
index e1f5d50..6044eba 100644
--- a/manifests/haproxy.pp
+++ b/manifests/haproxy.pp
@@ -593,6 +593,11 @@ class tripleo::haproxy (
service_port => $ports[manila_api_port],
ip_addresses => hiera('manila_api_node_ips', $controller_hosts_real),
server_names => $controller_hosts_names_real,
+ listen_options => {
+ 'http-request' => [
+ 'set-header X-Forwarded-Proto https if { ssl_fc }',
+ 'set-header X-Forwarded-Proto http if !{ ssl_fc }'],
+ },
public_ssl_port => $ports[manila_api_ssl_port],
}
}