1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192 |
- user apache;
- worker_processes 2;
- worker_rlimit_nofile 8192;
- worker_priority -5;
- timer_resolution 100ms;
- error_log /var/log/nginx/error.log info;
- pid /var/run/nginx.pid;
- env PATH;
- events {
- worker_connections 4000;
- accept_mutex on; # seems, this helps to spread connections across workers
- }
- 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"';
- access_log /var/log/nginx/access.log main;
- sendfile on;
- tcp_nopush on;
- keepalive_timeout 10;
- tcp_nodelay on;
- server_names_hash_bucket_size 128;
- gzip on;
- gzip_min_length 1100;
- gzip_buffers 4 8k;
- gzip_proxied any;
- gzip_vary on;
- gzip_types
- application/x-javascript
- text/xml
- application/atom+xml
- application/javascript
- application/json
- application/rss+xml
- application/vnd.ms-fontobject
- application/x-font-ttf
- application/x-web-app-manifest+json
- application/xhtml+xml
- application/xml
- font/opentype
- image/svg+xml
- image/x-icon
- text/css
- text/plain
- text/x-component;
- output_buffers 8 64k; # buffer for each one request. buffer exempt at the end of request.
- postpone_output 1460; # no output to the core, if accumulated less. It allows you to send full-sized TCP packets.
- proxy_buffers 64 64k;
- proxy_buffer_size 192k;
- proxy_max_temp_file_size 0; # zero value disables buffering of responses to temporary files.
-
- proxy_set_header X-Real-IP $remote_addr;
- proxy_set_header X-Forwarded-For $remote_addr;
- proxy_set_header X-Server-Address $server_addr;
- proxy_set_header Host $host;
- #proxy_set_header Host $http_host;
- proxy_set_header X-Forwarded-Proto $scheme;
- proxy_set_header X-Scheme $scheme;
- proxy_read_timeout 600;
- proxy_send_timeout 600;
- open_file_cache max=4000 inactive=60s;
- open_file_cache_valid 60s;
- open_file_cache_min_uses 2;
- open_file_cache_errors on;
- client_body_buffer_size 10M;
- client_max_body_size 10M;
- # limit_conn_zone $binary_remote_addr zone=limit_ips:8m;
- # limit_conn limit_ips 48;
- server{
- listen 127.0.0.1:8000;
- server_name 127.0.0.1;
- access_log off;
- error_log /dev/null;
- stub_status on;
- }
- include /etc/nginx/lcwm2/custom/*.conf;
|