forked from info-beamer/36c3-cms
-
Notifications
You must be signed in to change notification settings - Fork 2
/
infobeamer-cms-nginx.conf
62 lines (50 loc) · 1.95 KB
/
infobeamer-cms-nginx.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
server {
server_name infobeamer-cms.example.org;
root /var/www/infobeamer-cms/;
index index.html index.htm;
listen 80;
listen [::]:80;
location / {
return 308 https://$host$request_uri;
}
}
server {
server_name infobeamer-cms.example.org;
root /var/www/infobeamer-cms/;
index index.html index.htm;
listen 443 ssl http2;
listen [::]:443 ssl http2;
ssl_certificate /etc/ssl/certs/infobeamer-cms.example.org/fullchain.pem;
ssl_certificate_key /etc/ssl/certs/infobeamer-cms.example.org/privkey.pem;
ssl_dhparam /etc/ssl/certs/dhparam.pem;
ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384;
ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:10m;
ssl_session_tickets off;
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
resolver 8.8.8.8 8.8.4.4 valid=300s;
resolver_timeout 5s;
add_header Referrer-Policy same-origin;
add_header X-Frame-Options "SAMEORIGIN";
add_header X-Content-Type-Options nosniff;
add_header X-XSS-Protection "1; mode=block";
add_header Permissions-Policy interest-cohort=();
location / {
proxy_pass http://127.0.0.1:8000;
proxy_http_version 1.1;
proxy_set_header Host infobeamer-cms.example.org;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Host infobeamer-cms.example.org;
proxy_buffering off;
proxy_read_timeout 60;
client_max_body_size 5M;
}
location /static {
alias /opt/infobeamer-cms/static;
}
location /sync {
return 403 'forbidden';
}
}