diff options
Diffstat (limited to 'config/networking/services/dns.nix')
| -rw-r--r-- | config/networking/services/dns.nix | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/config/networking/services/dns.nix b/config/networking/services/dns.nix new file mode 100644 index 0000000..beed1e7 --- /dev/null +++ b/config/networking/services/dns.nix @@ -0,0 +1,18 @@ +{ config, ... }: + +let cfg = config.personal.networking; +in { + services.unbound = { + enable = true; + settings = { + server = { + interface = [ "127.0.0.1" "${cfg.subnets.private}.1" ]; + access-control = [ + "0.0.0.0/0 refuse" + "127.0.0.0/8 allow" + "${cfg.subnets.private}.0/24 allow" + ]; + }; + }; + }; +} |
