ソースを参照

Merge pull request #433 from wcbing/patch-1

fix: http-to-https use $host and 308
Jacky 1 年間 前
コミット
7fb84597cf
1 ファイル変更2 行追加2 行削除
  1. 2 2
      template/block/http-to-https.conf

+ 2 - 2
template/block/http-to-https.conf

@@ -11,9 +11,9 @@ value = ""
 
 {{- if .host }}
     if ($host == {{ .host }}) {
-        return 307 https://$server_name$request_uri;
+        return 308 https://$host$request_uri;
     }
     return 404;
 {{ else }}
-return 307 https://$server_name$request_uri;
+return 308 https://$host$request_uri;
 {{- end }}