forked from tobami/codespeed
-
-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathnginx.conf
More file actions
30 lines (22 loc) · 682 Bytes
/
nginx.conf
File metadata and controls
30 lines (22 loc) · 682 Bytes
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
upstream app_server_speedcenter {
server localhost:8000 fail_timeout=0;
}
server {
listen 80; ## listen for ipv4
listen [::]:88 default ipv6only=on; ## listen for ipv6
server_name localhost;
access_log /var/log/nginx/localhost.access.log;
# path for static files
location ~ ^/static/(.*)$ {
alias /home/vagrant/codespeed/speed_python/sitestatic/$1;
}
location / {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
if (!-f $request_filename) {
proxy_pass http://app_server_speedcenter;
break;
}
}
}