upstream moby_dick {
    server web:8000;
}

server {
    listen 80;
    client_body_buffer_size 100M;

    location / {
        proxy_pass http://moby_dick;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header Host $host;
        proxy_redirect off;
        client_max_body_size 100M;
    }

    location /static/ {
        alias /app/staticfiles/;
    }

    location /media/ {
        alias /app/mediafiles/;
    }
}

