From 7e513d929002f0711a021382b91a53eb813f2c50 Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Tue, 19 Nov 2024 23:49:57 -0600 Subject: [PATCH] Add Matrix host --- hosts/genesis/net/hosts | 4 ++++ hosts/genesis/networking/dhcp.nix | 5 +++++ hosts/isaiah/default.nix | 31 +++++++++++++++++-------------- 3 files changed, 26 insertions(+), 14 deletions(-) diff --git a/hosts/genesis/net/hosts b/hosts/genesis/net/hosts index 1c9641f..e686446 100644 --- a/hosts/genesis/net/hosts +++ b/hosts/genesis/net/hosts @@ -15,6 +15,10 @@ 10.42.1.9 ivr ivr.thehellings.lan 10.42.1.12 tv +# VMs +10.42.4.1 matrix matrix.thehellings.lan + +# IPMI 10.42.100.6 isaiahbmc isaiahbmc.thehellings.lan # Tailscale hosts diff --git a/hosts/genesis/networking/dhcp.nix b/hosts/genesis/networking/dhcp.nix index ca8d265..6e47005 100644 --- a/hosts/genesis/networking/dhcp.nix +++ b/hosts/genesis/networking/dhcp.nix @@ -117,6 +117,11 @@ ip-address = "10.42.1.9"; } + { + hw-address = "52:54:00:2a:74:2f"; + ip-address = "10.43.4.1"; + } + ######################################## # IOT devices # ######################################## diff --git a/hosts/isaiah/default.nix b/hosts/isaiah/default.nix index 04bed7f..fc2dea3 100644 --- a/hosts/isaiah/default.nix +++ b/hosts/isaiah/default.nix @@ -14,6 +14,10 @@ virtualisation.libvirtd = { enable = true; + allowedBridges = [ + "virbr0" + "br0" + ]; onBoot = "ignore"; # only restart VMs labeled 'autostart' qemu.ovmf.enable = true; }; @@ -31,11 +35,8 @@ address = " 10.42.1.1"; interface = "enp38s0"; }; - vlans = { - san = { - id = 616; - interface = "enp39s0"; - }; + bridges = { + br0.interfaces = [ "enp39s0" ]; }; interfaces = { enp38s0 = { @@ -44,22 +45,19 @@ address = "10.42.1.6"; prefixLength = 16; } - { - address = "10.42.100.1"; - prefixLength = 16; - } ]; }; - san = { + br0 = { ipv4.addresses = [ { - address = "10.201.1.1"; - prefixLength = 24; + address = "10.42.90.1"; + prefixLength = 16; } ]; }; }; nameservers = [ "10.42.1.5" ]; + firewall.checkReversePath = lib.mkForce false; }; users = { users = { @@ -76,8 +74,13 @@ }; system.stateVersion = lib.mkForce "24.05"; boot = { + binfmt.emulatedSystems = [ "aarch64-linux" ]; extraModprobeConfig = "options kvm_amd nested=1"; - supportedFilesystems = [ "ntfs" ]; + kernel.sysctl = { + "net.bridge.bridge-nf-call-ip6tables" = 0; + "net.bridge.bridge-nf-call-iptables" = 0; + "net.bridge.bridge-nf-call-arptables" = 0; + }; loader = { efi = { canTouchEfiVariables = true; @@ -88,7 +91,7 @@ configurationLimit = 10; }; }; - binfmt.emulatedSystems = [ "aarch64-linux" ]; + supportedFilesystems = [ "ntfs" ]; }; nixpkgs.config = { allowUnfree = true;