From c10c6d5a0971e12227d8131005e47dbc6a89a117 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=98ystein=20Tveit?= Date: Mon, 9 Dec 2024 21:30:54 +0100 Subject: [PATCH] hosts/ustetind: init --- flake.nix | 6 ++++++ hosts/ustetind/configuration.nix | 28 ++++++++++++++++++++++++++++ values.nix | 4 ++++ 3 files changed, 38 insertions(+) create mode 100644 hosts/ustetind/configuration.nix diff --git a/flake.nix b/flake.nix index ca2d900..b35930c 100644 --- a/flake.nix +++ b/flake.nix @@ -115,6 +115,12 @@ #ildkule-unstable = unstableNixosConfig "ildkule" { }; shark = stableNixosConfig "shark" { }; + ustetind = stableNixosConfig "ustetind" { + modules = [ + "${nixpkgs}/nixos/modules/virtualisation/lxc-container.nix" + ]; + }; + brzeczyszczykiewicz = stableNixosConfig "brzeczyszczykiewicz" { modules = [ inputs.grzegorz-clients.nixosModules.grzegorz-webui diff --git a/hosts/ustetind/configuration.nix b/hosts/ustetind/configuration.nix new file mode 100644 index 0000000..b2a293b --- /dev/null +++ b/hosts/ustetind/configuration.nix @@ -0,0 +1,28 @@ +{ config, fp, pkgs, lib, values, ... }: + +{ + imports = [ + (fp /base) + (fp /misc/metrics-exporters.nix) + ]; + + networking.hostName = "ustetind"; + + networking.useHostResolvConf = lib.mkForce false; + # systemd.network.enable = lib.mkForce false; + # networking.useDHCP = lib.mkForce true; + # networking.address = with values.hosts.georg; [ (ipv4 + "/25") (ipv6 + "/64") ]; + + systemd.network.networks."30-lxc-veth" = values.defaultNetworkConfig // { + matchConfig = { + Type = "ether"; + Kind = "veth"; + Name = [ + "eth*" + ]; + }; + address = with values.hosts.ustetind; [ (ipv4 + "/25") (ipv6 + "/64") ]; + }; + + system.stateVersion = "24.11"; +} diff --git a/values.nix b/values.nix index 2e9d266..cd8e26d 100644 --- a/values.nix +++ b/values.nix @@ -60,6 +60,10 @@ in rec { ipv4 = pvv-ipv4 204; ipv6 = pvv-ipv6 "1:4f"; # Wtf øystein og daniel why }; + ustetind = { + ipv4 = pvv-ipv4 234; + ipv6 = pvv-ipv6 234; + }; }; defaultNetworkConfig = {