nk20/nginx_note.conf_docker

28 lines
696 B
Plaintext
Raw Normal View History

2020-08-09 18:33:48 +00:00
# This is an example NGINX site configuration for note_kfet in Docker
# Only HTTP, please use a reverse proxy to secure it!
2020-06-21 18:27:42 +00:00
server {
2020-08-09 18:33:48 +00:00
# Serve this site by default on HTTP
listen 80 default_server;
listen [::]:80 default_server;
2020-06-21 18:27:42 +00:00
2020-08-09 18:33:48 +00:00
# Max upload size
client_max_body_size 75M;
2020-06-21 18:27:42 +00:00
2020-08-09 18:33:48 +00:00
# Django statics and media
2020-06-21 18:27:42 +00:00
location /static {
2020-08-09 18:33:48 +00:00
alias /code/static;
}
location /media {
alias /code/media;
2020-06-21 18:27:42 +00:00
}
2020-08-09 18:33:48 +00:00
# Send all non-media requests to the Django server.
location / {
proxy_pass http://127.0.0.1:8000;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $host;
proxy_redirect off;
2020-06-21 18:27:42 +00:00
}
}