From e84e6dcf117080eaf7658b25fb20a9dc3b5d1cfe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karel=20Ko=C4=8D=C3=AD?= Date: Sun, 24 Mar 2024 19:05:39 +0100 Subject: Add wireguard and more updates --- nixos/configurations/dean.nix | 45 +++++++++++++++++++++++-------------------- 1 file changed, 24 insertions(+), 21 deletions(-) (limited to 'nixos/configurations/dean.nix') diff --git a/nixos/configurations/dean.nix b/nixos/configurations/dean.nix index b91083c..44feaea 100644 --- a/nixos/configurations/dean.nix +++ b/nixos/configurations/dean.nix @@ -1,35 +1,38 @@ {pkgs, ...}: { - nixpkgs.hostPlatform.system = "aarch64-linux"; + turris.board = "mox"; + deploy.enable = true; cynerd = { - openvpn = { - oldpersonal = true; - }; + wireguard = true; monitoring.speedtest = true; }; networking = { - bridges = { - brlan = { - interfaces = [ - "eth0" - "lan1" - "lan2" - "lan3" - "lan4" - ]; + useNetworkd = true; + useDHCP = false; + }; + systemd.network = { + netdevs."brlab".netdevConfig = { + Kind = "bridge"; + Name = "brlan"; + }; + networks = { + "brlan" = { + matchConfig.Name = "brlan"; + networkConfig = { + DHCP = "yes"; + IPv6AcceptRA = "yes"; + }; + }; + "lan-brlan" = { + matchConfig.Name = "lan* end0"; + networkConfig.Bridge = "brlan"; }; }; - dhcpcd.allowInterfaces = ["brlan"]; + # TODO investigate why it doesn't work + wait-online.enable = false; }; - swapDevices = [ - { - device = "/var/swap"; - priority = 1; - } - ]; - environment.systemPackages = with pkgs; [ #openocd tio -- cgit v1.2.3