瀏覽代碼

Update nginx config

Daniel Supernault 2 年之前
父節點
當前提交
ee3b6e09b0
共有 1 個文件被更改,包括 2 次插入4 次删除
  1. 2 4
      contrib/nginx.conf

+ 2 - 4
contrib/nginx.conf

@@ -15,7 +15,7 @@ server {
     add_header X-XSS-Protection "1; mode=block";
     add_header X-XSS-Protection "1; mode=block";
     add_header X-Content-Type-Options "nosniff";
     add_header X-Content-Type-Options "nosniff";
 
 
-    index index.html index.htm index.php;
+    index index.php;
 
 
     charset utf-8;
     charset utf-8;
     client_max_body_size 15M;
     client_max_body_size 15M;
@@ -31,11 +31,9 @@ server {
 
 
     location ~ \.php$ {
     location ~ \.php$ {
         fastcgi_split_path_info ^(.+\.php)(/.+)$;
         fastcgi_split_path_info ^(.+\.php)(/.+)$;
-        try_files $fastcgi_script_name =404;
-        fastcgi_pass unix:/run/php-fpm/php-fpm.sock; # make sure this is correct
+        fastcgi_pass unix:/var/run/php/php8.1-fpm.sock;
         fastcgi_index index.php;
         fastcgi_index index.php;
         include fastcgi_params;
         include fastcgi_params;
-        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; # or $request_filename
     }
     }
 
 
     location ~ /\.(?!well-known).* {
     location ~ /\.(?!well-known).* {