Skip to content

Commit eeab425

Browse files
committed
fix: unknown "trust_forwarded_proto" variable error when run with already created old virtual hosts
1 parent b7402d4 commit eeab425

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

docker/rootfs/etc/nginx/conf.d/include/force-ssl.conf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,10 @@ if ($request_uri = /.well-known/acme-challenge/test-challenge) {
88

99
# Check if the ssl staff has been handled
1010
set $test_ssl_handled "";
11-
if ($trust_forwarded_proto = T){
11+
if ($trust_forwarded_proto = "") {
12+
set $trust_forwarded_proto "F";
13+
}
14+
if ($trust_forwarded_proto = "T") {
1215
set $test_ssl_handled "${test_ssl_handled}T";
1316
}
1417
if ($http_x_forwarded_proto = "https") {

0 commit comments

Comments
 (0)