-
Notifications
You must be signed in to change notification settings - Fork 4
/
nginx.conf
87 lines (66 loc) · 2.6 KB
/
nginx.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
master_process on;
daemon off;
user www-data www-data;
worker_processes auto;
error_log logs/error-nginx.log;
error_log logs/error-nginx.log notice;
error_log logs/error-nginx.log info;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
sendfile on;
keepalive_timeout 15;
gzip on;
gzip_comp_level 2;
gzip_min_length 1000;
gzip_proxied expired no-cache no-store private auth;
gzip_types text/plain application/x-javascript text/xml text/css application/xml;
server {
listen 80 default_server;
server_name localhost;
root /usr/local/nginx/html;
index index.php index.html index.htm;
access_log logs/http-access.log main;
location ~ \.php {
include fastcgi_params;
fastcgi_keep_conn on;
fastcgi_index index.php;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_intercept_errors on;
fastcgi_pass unix:/var/run/php-fpm.sock;
}
}
# server {
# listen 443 ssl;
# server_name localhost;
# ssl_protocols TLSv1.2 TLSv1.1 TLSv1;
# ssl_prefer_server_ciphers on;
# ssl_ciphers "EECDH+ECDSA+AESGCM EECDH+aRSA+AESGCM EECDH+ECDSA+SHA384 EECDH+ECDSA+SHA256 EECDH+aRSA+SHA384 EECDH+aRSA+SHA256 EECDH+aRSA+RC4 EECDH EDH+aRSA !aNULL !eNULL !LOW !3DES !MD5 !EXP !PSK !SRP !DSS !RC4 !MEDIUM";
# ssl_certificate /etc/ssl/private/cert.pem;
# ssl_certificate_key /etc/ssl/private/cert.key;
# ssl_session_cache shared:SSL:10m;
# ssl_session_timeout 5m;
# root /usr/local/nginx/html;
# index index.php index.html index.htm;
# access_log logs/https-access.log main;
# location ~ \.php {
# include fastcgi_params;
# fastcgi_keep_conn on;
# fastcgi_index index.php;
# fastcgi_split_path_info ^(.+\.php)(/.+)$;
# fastcgi_param PATH_INFO $fastcgi_path_info;
# fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
# fastcgi_intercept_errors on;
# fastcgi_pass unix:/var/run/php-fpm.sock;
# }
# }
}