Last active
February 6, 2018 03:40
-
-
Save kazeburo/7b0385cce1b0a4565581 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
user nobody nobody; | |
daemon off; | |
error_log /var/log/nginx/error.log; | |
pid /var/run/nginx.pid; | |
worker_rlimit_nofile 200000; | |
worker_processes 1; | |
pcre_jit on; | |
events { | |
use epoll; | |
worker_connections 10000; | |
} | |
http { | |
include /etc/nginx/mime.types; | |
default_type text/html; | |
sendfile on; | |
tcp_nopush on; | |
tcp_nodelay on; | |
send_timeout 60; | |
keepalive_timeout 60; | |
keepalive_requests 3000; | |
client_header_timeout 5; | |
client_body_timeout 30; | |
client_body_temp_path /dev/shm/client_temp 1 1; | |
client_max_body_size 10m; | |
client_body_buffer_size 32k; | |
client_header_buffer_size 2k; | |
large_client_header_buffers 4 8k; | |
proxy_connect_timeout 5; | |
proxy_send_timeout 5; | |
proxy_read_timeout 60; | |
proxy_buffering off; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_temp_path /dev/shm/proxy_temp 1 1; | |
proxy_cache_path /dev/shm/cache levels=1:2 keys_zone=cache-space:20m ax_size=300m inactive=10m; | |
server_tokens off; | |
#access_log /var/log/nginx/access.log main; | |
access_log off; | |
upstream apps { | |
server unix:/tmp/app.sock; | |
#server localhost:5000; | |
} | |
server { | |
listen 80; | |
server_name _; | |
etag off; | |
location / { | |
proxy_set_header Host $host; | |
proxy_pass http://apps; | |
} | |
location = /favicon.ico { | |
open_file_cache max=100; | |
root /home/isu-user/isucon/webapp/public; | |
} | |
location ~ ^/(img|css|js)/ { | |
open_file_cache max=100; | |
root /home/isu-user/isucon/webapp/public; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment