Add Onion-Location header

This commit is contained in:
Emelie Graven 2021-11-26 14:51:00 +01:00
parent 10539c295b
commit df554c6048
Signed by: emelie
GPG key ID: C11123726DBB55A1

View file

@ -6,6 +6,14 @@
enableACME = true;
forceSSL = true;
root = "/var/www/nixaalb.org/public";
extraConfig = ''
add_header Content-Security-Policy "script-src 'self'; object-src 'none'; base-uri 'none';" always;
add_header 'Referrer-Policy' 'same-origin';
add_header X-Frame-Options DENY;
add_header X-Content-Type-Options nosniff;
add_header X-XSS-Protection "1; mode=block";
add_header Onion-Location http://http://ag6mlqzpyswq3oogpnuykgllnv5gevjew6dshzmotwgnpo5jw2jqltad.onion$request_uri;
'';
};
"mta-sts.nixaalb.org" = {
enableACME = true;
@ -19,11 +27,9 @@
port = 8080;
} ];
root = "/var/www/nixaalb.org/public";
};
};
systemd.services.nginx.serviceConfig = {
PrivateTmp = lib.mkForce "false";
};
}