38 lines
1.2 KiB
Django/Jinja
38 lines
1.2 KiB
Django/Jinja
server {
|
|
|
|
listen 443 ssl;
|
|
listen [::]:443 ssl; # listen for ipv6
|
|
|
|
server_name {{ mayan_url }};
|
|
|
|
location / {
|
|
proxy_pass http://{{ bridgewithdns.mayan }}:8000; # /
|
|
|
|
proxy_redirect off;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header X-Forwarded-Host $server_name;
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
|
|
}
|
|
|
|
access_log /var/log/nginx/access_{{ mayan_url }}.log main;
|
|
error_log /var/log/nginx/error_{{ mayan_url }}.log warn;
|
|
|
|
ssl_session_timeout 5m;
|
|
|
|
ssl_certificate /etc/letsencrypt/live/{{ domain }}/fullchain.pem;
|
|
ssl_certificate_key /etc/letsencrypt/live/{{ domain }}/privkey.pem;
|
|
|
|
add_header Referrer-Policy "no-referrer" always;
|
|
add_header X-Content-Type-Options "nosniff" always;
|
|
add_header X-Download-Options "noopen" always;
|
|
add_header X-Frame-Options "SAMEORIGIN" always;
|
|
add_header X-Permitted-Cross-Domain-Policies "none" always;
|
|
add_header X-Robots-Tag "none" always;
|
|
add_header X-XSS-Protection "1; mode=block" always;
|
|
|
|
fastcgi_hide_header X-Powered-By;
|
|
}
|