mirror of
https://github.com/aykhans/series-robot-web.git
synced 2025-04-16 04:53:11 +00:00
38 lines
917 B
Plaintext
38 lines
917 B
Plaintext
upstream django_server{
|
|
server django:8000;
|
|
}
|
|
|
|
server {
|
|
listen 80;
|
|
server_name series-notification.online;
|
|
|
|
location /.well-known/acme-challenge/ {
|
|
root /var/www/certbot;
|
|
}
|
|
|
|
location / {
|
|
return 301 https://series-notification.online$request_uri;
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen 443 ssl;
|
|
server_name series-notification.online;
|
|
|
|
ssl_certificate /etc/letsencrypt/live/series-notification.online/fullchain.pem;
|
|
ssl_certificate_key /etc/letsencrypt/live/series-notification.online/privkey.pem;
|
|
include /etc/letsencrypt/options-ssl-nginx.conf;
|
|
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
|
|
|
|
location / {
|
|
proxy_pass http://django_server;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header Host $host;
|
|
proxy_redirect off;
|
|
}
|
|
|
|
location /django_static/ {
|
|
alias /django_static/;
|
|
}
|
|
}
|