From ff189d805bad826cec4d78368dcd2f3757723eed Mon Sep 17 00:00:00 2001 From: Kjetil Orbekk Date: Tue, 31 May 2022 08:37:14 -0400 Subject: Update vpn --- modules/vpn.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules') diff --git a/modules/vpn.nix b/modules/vpn.nix index ff47c0a..65efb05 100644 --- a/modules/vpn.nix +++ b/modules/vpn.nix @@ -27,7 +27,7 @@ let mkPeer = hostConfig: { inherit (hostConfig) publicKey endpoint; - allowedIPs = hostConfig.ips; # ++ (lib.optionals (hostConfig.relay && !cfg.is_server) [ "0.0.0.0/0" "::/0" ]); + allowedIPs = hostConfig.ips ++ (lib.optionals (hostConfig.relay && !cfg.is_server) [ "::/0" ]); }; getPeers = host: @@ -65,7 +65,7 @@ in interfaces.vpn = { ips = hosts.${config.networking.hostName}.ips; privateKeyFile = "${config.age.secrets."${config.networking.hostName}-wireguard-key".path}"; - allowedIPsAsRoutes = false; + allowedIPsAsRoutes = true; listenPort = cfg.listenPort; peers = getPeers config.networking.hostName; }; -- cgit v1.2.3