adonis/config/http/captiveportal.nix
toufic ar caf60d32fb
Some checks failed
/ deploy (push) Failing after 14s
a little nginx hardening
2026-01-15 00:48:13 +02:00

17 lines
403 B
Nix

{config, ...}: let
domain = config.customOps.domain;
in {
services.nginx.virtualHosts."cpcheck.${domain}" = {
extraConfig = ''
access_log off;
error_log off;
add_header Content-Security-Policy "default-src 'none'";
add_header 'Referrer-Policy' 'same-origin';
'';
locations."/".return = 204;
forceSSL = false;
addSSL = true;
enableACME = true;
};
}