-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathnginx.conf
63 lines (42 loc) · 1.44 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
#user nobody;
worker_processes auto;
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#pid logs/nginx.pid;
worker_rlimit_nofile 100000;
events {
worker_connections 20000;
multi_accept on;
}
http {
include mime.types;
default_type application/octet-stream;
log_subrequest on;
log_format access '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for" $upstream_cache_status $upstream_addr $upstream_connect_time "$http_range"';
#access_log logs/access.log main;
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 15;
#gzip on;
server {
listen 80;
server_name localhost;
location / {
proxy_pass http://$host;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
}
# This defines where your whole cache lives and its max size
# The max_size should be less than the size of your overall filesystem
# The keys_zone size value should be at least 100m, but should be significantly
# less than your available RAM
proxy_cache_path /cache/cache_data keys_zone=cache:1000m levels=1:2:2 inactive=300d max_size=10000g;
include "/etc/nginx/conf.d/*.conf";
}