mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-01-21 22:11:33 +01:00
resolved: Init module
This commit is contained in:
parent
de18f587c7
commit
2ffefb5f30
2 changed files with 26 additions and 13 deletions
26
modules/system/services/resolved.nix
Normal file
26
modules/system/services/resolved.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
ports = [
|
||||
53
|
||||
5353
|
||||
5355
|
||||
];
|
||||
in
|
||||
{
|
||||
options.custom.services.resolved.enable = lib.mkEnableOption "" // {
|
||||
default = config.systemd.network.enable;
|
||||
};
|
||||
|
||||
config = lib.mkIf config.custom.services.resolved.enable {
|
||||
meta.ports = {
|
||||
tcp.list = ports;
|
||||
udp.list = ports;
|
||||
};
|
||||
|
||||
services.resolved = {
|
||||
enable = true;
|
||||
dnssec = "allow-downgrade";
|
||||
dnsovertls = "opportunistic";
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue