Skip to content

Commit 1151950

Browse files
authored
Update nginx.prod.conf (#25)
Signed-off-by: Alex Lambson <[email protected]>
1 parent 3d65143 commit 1151950

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

docker/nginx.prod.conf

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
user nginx;
22
worker_processes 4;
3+
error_log /var/log/nginx/error.log warn;
34
pid /var/run/nginx.pid;
45

56
events {
@@ -8,8 +9,10 @@ events {
89

910
http {
1011
server {
11-
listen 80;
12-
12+
listen 80 deferred;
13+
client_max_body_size 128M;
14+
server_name cncnet.org mapdb2.cncnet.org;
15+
1316
# Serve static files: js, static images, etc.
1417
location /static/ {
1518
alias /usr/share/nginx/html/static/; # The nginx container's mounted volume.
@@ -25,10 +28,11 @@ http {
2528
# Proxy requests to the Django app running in gunicorn
2629
location / {
2730
proxy_pass http://django:8000; # The Django app is exposed on the `django` container on port 8000
28-
proxy_set_header Host $host;
31+
proxy_set_header Host $http_host;
2932
proxy_set_header X-Real-IP $remote_addr;
3033
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
3134
proxy_set_header X-Forwarded-Proto $scheme;
35+
proxy_redirect off;
3236
}
3337
}
3438
}

0 commit comments

Comments
 (0)