From a876ea069407a88226872e8e4e57990fd45407ab Mon Sep 17 00:00:00 2001 From: lilly <li@lly.sh> Date: Sat, 15 Mar 2025 18:41:27 +0100 Subject: [PATCH] define jool system --- systems/default.nix | 1 + systems/jool.nat64.eh22.intern.nix | 26 ++++++++++++++++++++++ systems/sketchy-router.noc.eh22.intern.nix | 6 ++++- 3 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 systems/jool.nat64.eh22.intern.nix diff --git a/systems/default.nix b/systems/default.nix index 659ec40..5cc083d 100644 --- a/systems/default.nix +++ b/systems/default.nix @@ -49,6 +49,7 @@ in # prod hosts (public user) "cookies.eh22.intern" = mkSystem "x86_64-linux" "cookies.eh22.intern"; + "jool.nat64.eh22.intern" = mkSystem "x86_64-linux" "jool.nat64.eh22.intern"; # staging temp infra "sketchy-router.noc.eh22.intern" = mkSystem "x86_64-linux" "sketchy-router.noc.eh22.intern"; diff --git a/systems/jool.nat64.eh22.intern.nix b/systems/jool.nat64.eh22.intern.nix new file mode 100644 index 0000000..da90bfe --- /dev/null +++ b/systems/jool.nat64.eh22.intern.nix @@ -0,0 +1,26 @@ +{ + pkgs, + lib, + ... +}: +{ + imports = [ ]; + + # configure static IP address + networking.useDHCP = false; + systemd.network = { + enable = true; + networks = { + "10-eth0" = { + matchConfig.MACAddress = "BC:24:11:41:E1:61"; + address = [ "94.45.248.2/24" ]; + gateway = [ "BC:24:11:21:7F:AF" ]; + }; + }; + }; + + # DO NOT CHANGE + # this defines the first version of NixOS that was installed on the machine so that programs with non-migratable data files are kept compatible + home-manager.users.noc.home.stateVersion = "24.11"; + system.stateVersion = "24.11"; +} diff --git a/systems/sketchy-router.noc.eh22.intern.nix b/systems/sketchy-router.noc.eh22.intern.nix index 0fbd648..bf9d72c 100644 --- a/systems/sketchy-router.noc.eh22.intern.nix +++ b/systems/sketchy-router.noc.eh22.intern.nix @@ -42,7 +42,10 @@ in }; "10-ethPubUsr" = { matchConfig.Name = "ethPubUsr"; - address = [ "10.0.0.1/24" ]; + address = [ + "10.0.0.1/24" + "94.45.248.1/24" + ]; }; }; }; @@ -53,6 +56,7 @@ in internalIPs = [ "10.20.25.0/24" "10.0.0.0/24" + "94.45.248.0/24" ]; };