heartbeat
This commit is contained in:
38
nginx.conf
38
nginx.conf
@@ -1,30 +1,26 @@
|
||||
# Backend
|
||||
server {
|
||||
listen 4000 ssl http2;
|
||||
listen [::]:4000 ssl http2;
|
||||
server_name achievements.ajb.dk;
|
||||
|
||||
ssl_certificate /etc/letsencrypt/live/ajb.dk/fullchain.pem;
|
||||
ssl_certificate_key /etc/letsencrypt/live/ajb.dk/privkey.pem;
|
||||
|
||||
location / {
|
||||
proxy_pass http://localhost:4001/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header Host $host;
|
||||
}
|
||||
}
|
||||
|
||||
# Frontend (serve yew app static files)
|
||||
server {
|
||||
listen 443 ssl http2;
|
||||
listen [::]:443 ssl http2;
|
||||
server_name achievements.ajb.dk;
|
||||
|
||||
ssl_certificate /etc/letsencrypt/live/ajb.dk/fullchain.pem;
|
||||
ssl_certificate_key /etc/letsencrypt/live/ajb.dk/privkey.pem;
|
||||
ssl_certificate /etc/letsencrypt/live/git.ajb.dk/fullchain.pem; # managed by Certbot
|
||||
ssl_certificate_key /etc/letsencrypt/live/git.ajb.dk/privkey.pem; # managed by Certbot
|
||||
|
||||
# Backend
|
||||
location /api {
|
||||
proxy_pass http://localhost:4000;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header Host $host;
|
||||
|
||||
# Prevent websocket connections timing out after 1 minute.
|
||||
# This sets the timeout to 24 hours:
|
||||
proxy_read_timeout 86400;
|
||||
proxy_send_timeout 86400;
|
||||
}
|
||||
|
||||
# Frontend (serve yew app static files)
|
||||
location / {
|
||||
alias /var/www/achievements/;
|
||||
try_files $uri $uri/ /index.html;
|
||||
|
||||
Reference in New Issue
Block a user