This repository has been archived by the owner on Nov 17, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathnginx.prod.conf
73 lines (62 loc) · 1.65 KB
/
nginx.prod.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
63
64
65
66
67
68
69
70
71
72
73
# Enumerate all the Tornado servers here
upstream frontends {
server 127.0.0.1:8005;
server 127.0.0.1:8006;
server 127.0.0.1:8007;
server 127.0.0.1:8008;
}
server {
listen 67.215.241.35:80;
server_name mhjones.org;
# Allow file uploads
client_max_body_size 50M;
location /static/ {
alias /srv/www/domains/mhjones.org/static/;
if ($query_string) {
expires max;
}
}
location = /favicon.ico {
rewrite (.*) /static/favicon.ico;
}
location = /robots.txt {
rewrite (.*) /static/robots.txt;
}
location / {
proxy_pass_header Server;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Scheme $scheme;
proxy_pass http://frontends;
}
}
server {
listen 67.215.241.35:443;
server_name mhjones.org;
ssl on;
ssl_certificate /srv/www/domains/mhjones.org/mhjones.org.crt;
ssl_certificate_key /srv/www/domains/mhjones.org/mhjones.org.key;
# Allow file uploads
client_max_body_size 50M;
location /static/ {
alias /srv/www/domains/mhjones.org/static/;
if ($query_string) {
expires max;
}
}
location = /favicon.ico {
rewrite (.*) /static/favicon.ico;
}
location = /robots.txt {
rewrite (.*) /static/robots.txt;
}
location / {
proxy_pass_header Server;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Scheme $scheme;
proxy_pass http://frontends;
}
}