From feba291fa1e837caa72dc68f37ee99e57af5da13 Mon Sep 17 00:00:00 2001 From: Collin Williams <96917990+bluedragon1221@users.noreply.github.com> Date: Fri, 23 Jan 2026 15:25:51 -0600 Subject: changes to mercury --- modules/wireguard/nixos/default.nix | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'modules/wireguard/nixos/default.nix') diff --git a/modules/wireguard/nixos/default.nix b/modules/wireguard/nixos/default.nix index 706048e..9f05e43 100644 --- a/modules/wireguard/nixos/default.nix +++ b/modules/wireguard/nixos/default.nix @@ -6,6 +6,8 @@ cfg = config.collinux.wireguard; in lib.mkIf cfg.enable { + networking.firewall.checkReversePath = "loose"; + networking.useNetworkd = true; systemd.network = { enable = true; @@ -24,16 +26,14 @@ in wireguardPeers = cfg.peers |> builtins.mapAttrs (_: m: - if (m == null) - then { + { PublicKey = m.publicKey; AllowedIPs = [m.ip]; + PersistentKeepalive = 25; } - else { - PublicKey = m.publicKey; - AllowedIPs = [m.ip]; + // (lib.optionalAttrs (m.endpoint != null) { Endpoint = m.endpoint; - }) + })) |> builtins.attrValues; }; @@ -44,8 +44,6 @@ in Address = cfg.ip; DHCP = "no"; Gateway = cfg.gateway; - - IPv6AcceptRA = false; }; }; }; -- cgit v1.3.1