blob: 732f09f122b93a6d36c534980f9ad3b4bc01a31a (
plain)
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
63
64
65
66
67
68
69
70
71
72
73
74
75
|
server {
listen 80;
listen [::]:80;
server_name lists.fripost.org;
include snippets/acme-challenge.conf;
access_log /var/log/nginx/lists.access.log;
error_log /var/log/nginx/lists.error.log info;
location / {
return 301 https://$host$request_uri;
}
}
server {
listen 443;
listen [::]:443;
server_name lists.fripost.org;
access_log /var/log/nginx/lists.access.log;
error_log /var/log/nginx/lists.error.log info;
include snippets/headers.conf;
add_header Content-Security-Policy
"default-src 'none'; script-src 'self' 'unsafe-inline'; style-src 'self' 'unsafe-inline'; img-src 'self'; font-src 'self'; upgrade-insecure-requests; block-all-mixed-content; reflected-xss block; referrer no-referrer-when-downgrade; frame-ancestors 'none'; form-action 'self'; base-uri lists.fripost.org";
include snippets/ssl.conf;
ssl_certificate /etc/nginx/ssl/lists.fripost.org.pem;
ssl_certificate_key /etc/nginx/ssl/lists.fripost.org.key;
add_header Public-Key-Pins 'pin-sha256="OLx1hOEqnCdS/7ZgzTzAl8Ig/Cwpz5MY9J9Fishg6/0="; pin-sha256="v/Ow0Ou2m08HO10wxci1IVrMC/pbihnoDNxvUwKBsMY="; max-age=15778800';
location = / {
return 302 /sympa$args;
}
location ^~ /static-sympa/ {
alias /var/lib/sympa/static_content/;
expires 30d;
}
location ^~ /sympa {
fastcgi_split_path_info ^(/sympa)(.*)$;
include snippets/fastcgi.conf;
fastcgi_pass unix:/run/wwsympa.socket;
gzip off;
}
location ~* ^/([^/]+)/?$ {
return 302 /$1/sympa$args;
}
location ~* ^/([^/]+)/sympa(/.*)?$ {
set $vhost $1;
if (!-f /etc/sympa/$vhost/robot.conf) {
return 404;
}
fastcgi_split_path_info ^(/[^/]+/sympa)(.*)$;
include snippets/fastcgi.conf;
fastcgi_pass unix:/run/wwsympa.socket;
gzip off;
fastcgi_param SERVER_NAME $vhost;
}
location / {
return 404;
}
}
|