Skip to content

Commit 6d980b3

Browse files
committed
Allow X-Forwarded-Proto to set the HTTPS flag
1 parent 09b080e commit 6d980b3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

config/nginx.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ http {
2929
gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript application/javascript;
3030

3131
# Forward the cloudfront scheme from upstream
32-
map $http_cloudfront_forwarded_proto $forwarded_scheme {
32+
map "$http_cloudfront_forwarded_proto$http_x_forwarded_proto" $forwarded_scheme {
3333
default off;
34-
https on;
34+
"~*(https)" on;
3535
}
3636

3737
server {

0 commit comments

Comments
 (0)