We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents c53fd0f + f26c973 commit cba7ba4Copy full SHA for cba7ba4
1 file changed
router/templates/nginx.conf
@@ -91,6 +91,7 @@ http {
91
## end deis-store-gateway
92
93
## start service definitions for each application
94
+ {{ $useSSL := or .deis_router_sslCert "false" }}
95
{{ $domains := .deis_domains }}{{ range $service := .deis_services }}{{ if $service.Nodes }}
96
upstream {{ Base $service.Key }} {
97
{{ range $upstream := $service.Nodes }}server {{ $upstream.Value }};
@@ -104,7 +105,9 @@ http {
104
105
location / {
106
proxy_buffering off;
107
proxy_set_header Host $host;
108
+ {{ if ne $useSSL "false" }}
109
proxy_set_header X-Forwarded-Proto $scheme;
110
+ {{ end }}
111
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
112
proxy_redirect off;
113
proxy_connect_timeout 10s;
0 commit comments