2022-03-08 01:17:24 +04:00
|
|
|
server {
|
2022-05-24 18:01:00 +04:00
|
|
|
listen 443 ssl http2;
|
2022-08-29 20:06:58 +04:00
|
|
|
# listen 8090; # Tor
|
2022-05-24 18:01:00 +04:00
|
|
|
listen 127.0.0.1:8111; # I2P
|
2022-08-29 20:06:58 +04:00
|
|
|
listen [300:a98d:d6d0:8a08::e]:80; # Yggdrasil
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2023-02-23 17:49:01 +04:00
|
|
|
server_name radio.arav.su radio.arav.i2p mkgnmhmzqm7kyzv7jnzzafvgm7xlmlfvzhgorpapd5or2arnhuktqd.onion;
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
access_log /var/log/nginx/dwelling/radio.log main if=$nolog;
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2023-02-23 17:49:01 +04:00
|
|
|
ssl_certificate /etc/letsencrypt/live/arav.su/fullchain.pem;
|
|
|
|
ssl_certificate_key /etc/letsencrypt/live/arav.su/privkey.pem;
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
add_header Content-Security-Policy "default-src 'self'; script-src 'self'; style-src 'self'; img-src 'self'; media-src 'self'; object-src 'none'; frame-src 'none'; frame-ancestors 'none'; font-src 'self'; form-action 'none'";
|
|
|
|
add_header X-Frame-Options "DENY";
|
|
|
|
add_header X-Content-Type-Options "nosniff";
|
|
|
|
add_header X-XSS-Protection "1; mode=block";
|
|
|
|
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload";
|
2022-08-29 20:06:58 +04:00
|
|
|
# add_header Onion-Location "http://mkgnmhmzqm7kyzv7jnzzafvgm7xlmlfvzhgorpapd5or2arnhuktqd.onion$request_uri";
|
2022-03-08 01:17:24 +04:00
|
|
|
|
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
location / {
|
2023-02-07 02:25:18 +04:00
|
|
|
proxy_pass http://unix:/var/run/dwelling-radio/sock;
|
2022-08-29 20:06:58 +04:00
|
|
|
proxy_buffering off;
|
2022-05-24 18:01:00 +04:00
|
|
|
proxy_set_header X-Client-Timezone $gi2_location_tz;
|
2022-08-29 20:06:58 +04:00
|
|
|
proxy_set_header Host $host;
|
2022-05-24 18:01:00 +04:00
|
|
|
}
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
location /live/ {
|
2022-08-29 20:06:58 +04:00
|
|
|
proxy_pass http://127.0.0.1:8000/;
|
|
|
|
proxy_buffering off;
|
2022-05-24 18:01:00 +04:00
|
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
|
|
}
|
|
|
|
|
|
|
|
location /live/admin/ {
|
|
|
|
deny all;
|
|
|
|
}
|
2022-03-08 01:17:24 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
server {
|
2022-05-24 18:01:00 +04:00
|
|
|
listen 8000;
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2023-02-23 17:49:01 +04:00
|
|
|
server_name radio.arav.su;
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
access_log /var/log/nginx/dwelling/radio.http.log main if=$nolog;
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
add_header Content-Security-Policy "default-src 'none'; script-src 'none'; style-src 'self'; img-src 'self'; media-src 'self'; object-src 'none'; frame-src 'none'; frame-ancestors 'none'; font-src 'self'; form-action 'none'";
|
|
|
|
add_header X-Frame-Options "DENY";
|
|
|
|
add_header X-Content-Type-Options "nosniff";
|
|
|
|
add_header X-XSS-Protection "1; mode=block";
|
2023-02-19 21:24:56 +04:00
|
|
|
# add_header Onion-Location "http://mkgnmhmzqm7kyzv7jnzzafvgm7xlmlfvzhgorpapd5or2arnhuktqd.onion/live$request_uri";
|
2022-03-08 01:17:24 +04:00
|
|
|
|
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
location / {
|
2023-05-26 23:03:52 +04:00
|
|
|
proxy_pass http://127.0.0.1:8001/;
|
2022-05-24 18:01:00 +04:00
|
|
|
proxy_buffering off;
|
|
|
|
}
|
2022-03-08 01:17:24 +04:00
|
|
|
|
2022-05-24 18:01:00 +04:00
|
|
|
location /admin/ {
|
|
|
|
deny all;
|
|
|
|
}
|
2022-03-08 01:17:24 +04:00
|
|
|
}
|