mirror of
https://github.com/cloudpanel-io/vhost-templates.git
synced 2026-05-18 08:23:31 +08:00
.
This commit is contained in:
@@ -2,12 +2,8 @@
|
|||||||
server {
|
server {
|
||||||
listen 80;
|
listen 80;
|
||||||
listen [::]:80;
|
listen [::]:80;
|
||||||
listen 443 quic;
|
listen 443 ssl http2;
|
||||||
listen 443 ssl;
|
listen [::]:443 ssl http2;
|
||||||
listen [::]:443 quic;
|
|
||||||
listen [::]:443 ssl;
|
|
||||||
http2 on;
|
|
||||||
http3 off;
|
|
||||||
{{ssl_certificate_key}}
|
{{ssl_certificate_key}}
|
||||||
{{ssl_certificate}}
|
{{ssl_certificate}}
|
||||||
{{server_name}}
|
{{server_name}}
|
||||||
@@ -17,7 +13,7 @@ server {
|
|||||||
{{nginx_error_log}}
|
{{nginx_error_log}}
|
||||||
|
|
||||||
if ($scheme != "https") {
|
if ($scheme != "https") {
|
||||||
rewrite ^ https://$host$request_uri permanent;
|
rewrite ^ https://$host$uri permanent;
|
||||||
}
|
}
|
||||||
|
|
||||||
location ~ /.well-known {
|
location ~ /.well-known {
|
||||||
@@ -27,8 +23,6 @@ server {
|
|||||||
|
|
||||||
{{settings}}
|
{{settings}}
|
||||||
|
|
||||||
include /etc/nginx/global_settings;
|
|
||||||
|
|
||||||
try_files $uri $uri/ /index.php?$args;
|
try_files $uri $uri/ /index.php?$args;
|
||||||
index index.php index.html;
|
index index.php index.html;
|
||||||
|
|
||||||
@@ -47,7 +41,6 @@ server {
|
|||||||
|
|
||||||
location ~* ^.+\.(css|js|jpg|jpeg|gif|png|ico|gz|svg|svgz|ttf|otf|woff|woff2|eot|mp4|ogg|ogv|webm|webp|zip|swf)$ {
|
location ~* ^.+\.(css|js|jpg|jpeg|gif|png|ico|gz|svg|svgz|ttf|otf|woff|woff2|eot|mp4|ogg|ogv|webm|webp|zip|swf)$ {
|
||||||
add_header Access-Control-Allow-Origin "*";
|
add_header Access-Control-Allow-Origin "*";
|
||||||
add_header alt-svc 'h3=":443"; ma=86400';
|
|
||||||
expires max;
|
expires max;
|
||||||
access_log off;
|
access_log off;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user