diff --git a/nixos/agares/configuration.nix b/nixos/agares/configuration.nix index f49b083..6857930 100644 --- a/nixos/agares/configuration.nix +++ b/nixos/agares/configuration.nix @@ -22,7 +22,7 @@ services.smartd.enable = true; networking.hostName = "agares"; - networking.domain = "dadada.li"; + networking.domain = "bs.dadada.li"; # Use the GRUB 2 boot loader. boot.loader.grub.enable = true; diff --git a/nixos/gorgon/configuration.nix b/nixos/gorgon/configuration.nix index ee3485b..cbfefea 100644 --- a/nixos/gorgon/configuration.nix +++ b/nixos/gorgon/configuration.nix @@ -66,11 +66,6 @@ in luks.uuid = "3d0e5b93-90ca-412a-b4e0-3e6bfa47d3f4"; networking = { enableBsShare = true; - localResolver = { - enable = false; - uwu = true; - s0 = true; - }; vpnExtension = "3"; }; sway.enable = false; @@ -168,6 +163,11 @@ in networking.wireguard.interfaces.uwupn = { ips = [ "10.11.0.24/32" "fc00:1337:dead:beef::10.11.0.24/128" ]; privateKeyFile = "/var/lib/wireguard/uwu"; + + postSetup = '' + ${pkgs.systemd}/bin/resolvectl domain uwupn ~uwu + ${pkgs.systemd}/bin/resolvectl dns uwupn 10.0.0.1 + ''; peers = [ { publicKey = "tuoiOWqgHz/lrgTcLjX+xIhvxh9jDH6gmDw2ZMvX5T8="; diff --git a/nixos/ifrit/configuration.nix b/nixos/ifrit/configuration.nix index 6688019..9240083 100644 --- a/nixos/ifrit/configuration.nix +++ b/nixos/ifrit/configuration.nix @@ -18,6 +18,7 @@ in }; networking.hostName = "ifrit"; + networking.domain = "bs.dadada.li"; networking.hosts = { "127.0.0.1" = hostAliases; diff --git a/nixos/modules/networking.nix b/nixos/modules/networking.nix index 4187cc7..6e3a216 100644 --- a/nixos/modules/networking.nix +++ b/nixos/modules/networking.nix @@ -134,9 +134,11 @@ in dadada = { ips = [ "fd42:9c3b:f96d:201::${cfg.vpnExtension}/64" ]; listenPort = 51234; - privateKeyFile = "/var/lib/wireguard/privkey"; - + postSetup = '' + ${pkgs.systemd}/bin/resolvectl domain dadada ~bs.dadada.li + ${pkgs.systemd}/bin/resolvectl dns dadada fd42:9c3b:f96d:201:: + ''; peers = [ { publicKey = vpnPubKey; diff --git a/nixos/modules/profiles/base.nix b/nixos/modules/profiles/base.nix index 060b2c6..b60f01b 100644 --- a/nixos/modules/profiles/base.nix +++ b/nixos/modules/profiles/base.nix @@ -54,5 +54,8 @@ in highlighters = [ "main" "brackets" "pattern" "root" "line" ]; }; }; + + networking.networkmanager.dns = mkDefault "systemd-resolved"; + services.resolved.enable = mkDefault true; } diff --git a/nixos/ninurta/configuration.nix b/nixos/ninurta/configuration.nix index 76b0df3..9f62b8d 100644 --- a/nixos/ninurta/configuration.nix +++ b/nixos/ninurta/configuration.nix @@ -21,6 +21,7 @@ in dadada.backupClient.bs.enable = false; networking.hostName = "ninurta"; + networking.domain = "bs.dadada.li"; networking.hosts = { "127.0.0.1" = hostAliases; @@ -47,8 +48,8 @@ in hostKeys = [ initrdSshKey ]; }; postCommands = '' - echo 'systemctl restart systemd-cryptsetup@luks.service' >> /root/.profile - ''; + echo 'systemctl restart systemd-cryptsetup@luks.service' >> /root/.profile + ''; }; # Kinda does not work? systemd = { @@ -204,6 +205,8 @@ in "10-uwu" = { matchConfig.Name = "uwu"; address = [ "10.11.0.39/24" "fc00:1337:dead:beef::10.11.0.39/128" ]; + dns = [ "10.11.0.1::%uwu#uwu" ]; + domains = [ "uwu" ]; DHCP = "no"; networkConfig.IPv6AcceptRA = false; linkConfig.RequiredForOnline = "no";