Skip to content
Permalink
Browse files

keepalive via nginx

  • Loading branch information
sorah committed Oct 31, 2015
1 parent 382d8a7 commit 0d0f8c6792a0289f97f778d8d1dd7b44d0c3dc48
Showing with 21 additions and 3 deletions.
  1. +21 −3 5f/config/nginx.conf
@@ -8,12 +8,16 @@ events {

http {
upstream isu12 {
server isu12a:8080;
server isu12b:8080;
server isu12c:8080;
server isu12a:8081;
server isu12b:8081;
server isu12c:8081;
keepalive 8;
}

upstream unicorn {
server unix:/tmp/unicorn.sock;
}

log_format ltsv "status:$status"
"\ttime:$time_iso8601"
"\treqtime:$request_time"
@@ -69,4 +73,18 @@ http {
proxy_pass http://isu12;
}
}

server {
listen 8081;

location ~ ^/(js|css|fonts)/ {
root /home/isucon/shirokanezoo/5f/webapp/static;
expires max;
}

location / {
proxy_set_header Host $host;
proxy_pass http://unicorn;
}
}
}

0 comments on commit 0d0f8c6

Please sign in to comment.
You can’t perform that action at this time.