diff --git a/nix/nixos-module/network.nix b/nix/nixos-module/network.nix index 3c2f6bd..a2d64dc 100644 --- a/nix/nixos-module/network.nix +++ b/nix/nixos-module/network.nix @@ -33,9 +33,12 @@ in builtins.mapAttrs (ifName: { gw4, gw6, ... }: let netConfig = config.site.net.${ifName}; - in { + in rec { matchConfig.Name = ifName; + networkConfig.IPForward = + (builtins.length addresses) > 0; + addresses = let address = netConfig.hosts4.${hostName};