File tree 1 file changed +11
-6
lines changed
controllers/nginx/rootfs/etc/nginx/template
1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -108,6 +108,17 @@ http {
108
108
'' $scheme;
109
109
}
110
110
111
+ map $http_x_forwarded_port $pass_server_port {
112
+ default $http_x_forwarded_port;
113
+ '' $server_port;
114
+ }
115
+
116
+ # map port 442 to 443 for header X-Forwarded-Port
117
+ map $pass_server_port $pass_port {
118
+ 442 443;
119
+ default $pass_server_port;
120
+ }
121
+
111
122
# Map a response error watching the header Content-Type
112
123
map $http_accept $httpAccept {
113
124
default html;
@@ -196,12 +207,6 @@ http {
196
207
ssl_certificate_key {{ $server.SSLCertificate }};
197
208
{{ end }}
198
209
199
- # map port 442 to 443 for header X-Forwarded-Port
200
- map $pass_port $server_port {
201
- 442 443;
202
- default 80;
203
- }
204
-
205
210
{{ if (and (not (empty $server.SSLCertificate)) $cfg.HSTS) }}
206
211
more_set_headers "Strict-Transport-Security: max-age={{ $cfg.HSTSMaxAge }}{{ if $cfg.HSTSIncludeSubdomains }}; includeSubDomains{{ end }}; preload";
207
212
{{ end }}
You can’t perform that action at this time.
0 commit comments