mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
39 lines
1.2 KiB
Plaintext
39 lines
1.2 KiB
Plaintext
user root root;
|
|
worker_processes auto;
|
|
pid |PID|;
|
|
events {
|
|
worker_connections 1024;
|
|
}
|
|
http {
|
|
include /etc/nginx/mime.types;
|
|
sendfile on;
|
|
keepalive_timeout 65;
|
|
server {
|
|
listen |PORT|;
|
|
listen [::]:|PORT|;
|
|
|ssl_certificate|
|
|
|ssl_certificate_key|
|
|
ssl_session_cache shared:SSL:1m;
|
|
ssl_session_timeout 5m;
|
|
ssl_ciphers HIGH:!aNULL:!MD5;
|
|
ssl_prefer_server_ciphers on;
|
|
server_name localhost;
|
|
root |project_directory|;
|
|
index index.html index.htm index.php;
|
|
location ~ \.php(.*)$ {
|
|
fastcgi_pass unix:|SOCK|; # 通过 Unix 套接字执行 PHP
|
|
fastcgi_index index.php;
|
|
fastcgi_split_path_info ^(.+\.php)(.*)$;
|
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; # 修复 Nginx fastcgi 漏洞
|
|
fastcgi_param PATH_INFO $fastcgi_path_info;
|
|
include /etc/nginx/fastcgi_params;
|
|
client_max_body_size |upload_max_filesize|;
|
|
client_body_temp_path |temp_path|;
|
|
client_body_timeout 3600s;
|
|
fastcgi_connect_timeout 3600s;
|
|
fastcgi_send_timeout 3600s;
|
|
fastcgi_read_timeout 3600s;
|
|
}
|
|
}
|
|
}
|