-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathservers.conf.erb
45 lines (43 loc) · 1.29 KB
/
servers.conf.erb
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
# ERB templated nginx configuration
# see https://doc.scalingo.com/platform/deployment/buildpacks/nginx
server {
listen <%= ENV["PORT"] %>;
server_name _;
root /app/;
# static files of django
location /static/ {
autoindex off;
}
# express
location / {
proxy_pass http://localhost:8001;
proxy_set_header Host $host ;
proxy_set_header X-Real-IP $remote_addr ;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
}
# django
location /admin {
proxy_pass http://localhost:8002;
proxy_set_header Host $host ;
proxy_set_header X-Real-IP $remote_addr ;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
}
location /accounts {
proxy_pass http://localhost:8002;
proxy_set_header Host $host ;
proxy_set_header X-Real-IP $remote_addr ;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
}
location /processes {
proxy_pass http://localhost:8001;
proxy_set_header Host $host ;
proxy_set_header X-Real-IP $remote_addr ;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
}
location /versions {
proxy_pass http://localhost:8001;
proxy_set_header Host $host ;
proxy_set_header X-Real-IP $remote_addr ;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
}
}