diff options
| author | Grisha Shipunov | 2025-01-12 21:32:36 +0100 |
|---|---|---|
| committer | Grisha Shipunov | 2025-01-12 21:32:36 +0100 |
| commit | bd44fc6fcb1fe3df7b8a8c81839e34470fed7911 (patch) | |
| tree | f1a6118da93cac4f533bb001ccbb43ff18366ef3 /hosts | |
| parent | ea46b0bb1edd0c76f9c6cf9dfcc905396e9f66b1 (diff) | |
authentik: init
Diffstat (limited to 'hosts')
| -rw-r--r-- | hosts/cloud/secrets.nix | 3 | ||||
| -rw-r--r-- | hosts/minime/hardware-configuration.nix | 6 | ||||
| -rw-r--r-- | hosts/minime/networking/default.nix | 3 | ||||
| -rw-r--r-- | hosts/minime/networking/uvm.nix | 32 | ||||
| -rw-r--r-- | hosts/minime/uvm.nix | 10 |
5 files changed, 50 insertions, 4 deletions
diff --git a/hosts/cloud/secrets.nix b/hosts/cloud/secrets.nix index d9d5b51..e1d492f 100644 --- a/hosts/cloud/secrets.nix +++ b/hosts/cloud/secrets.nix @@ -7,5 +7,8 @@ "wg/0xa-mgmt" = { owner = config.users.users.systemd-network.name; }; + "wg/0xa-proxy" = { + owner = config.users.users.systemd-network.name; + }; }; } diff --git a/hosts/minime/hardware-configuration.nix b/hosts/minime/hardware-configuration.nix index 7e17821..ae2a528 100644 --- a/hosts/minime/hardware-configuration.nix +++ b/hosts/minime/hardware-configuration.nix @@ -65,6 +65,12 @@ options = [ "zfsutil" ]; }; + fileSystems."/var/lib/microvms" = { + device = "zpool/data/var/lib/microvms"; + fsType = "zfs"; + options = [ "zfsutil" ]; + }; + swapDevices = [ { device = "/dev/disk/by-partuuid/7e7d0e0b-90b7-465c-a022-089b38e0f16d"; diff --git a/hosts/minime/networking/default.nix b/hosts/minime/networking/default.nix index b1c044f..25e20b3 100644 --- a/hosts/minime/networking/default.nix +++ b/hosts/minime/networking/default.nix @@ -1,4 +1,5 @@ -{ ... }: { +{ ... }: +{ imports = [ ./uplink.nix ./uvm.nix diff --git a/hosts/minime/networking/uvm.nix b/hosts/minime/networking/uvm.nix index 15e498e..dfcb14c 100644 --- a/hosts/minime/networking/uvm.nix +++ b/hosts/minime/networking/uvm.nix @@ -1,8 +1,10 @@ -{ ... }: { +{ ... }: +{ + # TODO: make a module systemd.network = { netdevs."10-uvm-br" = { netdevConfig = { - Kind = bridge; + Kind = "bridge"; Name = "uvm-br"; }; }; @@ -13,7 +15,31 @@ DHCPServer = false; IPv6SendRA = true; }; - Address = [ ]; + addresses = [ + { + Address = "10.99.99.1/24"; + } + { + Address = "fd12:3456:789a::1/64"; + } + ]; + ipv6Prefixes = [ + { + Prefix = "fd12:3456:789a::/64"; + } + ]; }; + + networks."11-uvm-br" = { + matchConfig.Name = "uvm-*"; + networkConfig.Bridge = "uvm-br"; + }; + + }; + networking.nat = { + enable = true; + enableIPv6 = true; + externalInterface = "enp90s0"; + internalInterfaces = [ "uvm-br" ]; }; } diff --git a/hosts/minime/uvm.nix b/hosts/minime/uvm.nix new file mode 100644 index 0000000..7f10579 --- /dev/null +++ b/hosts/minime/uvm.nix @@ -0,0 +1,10 @@ +{ inputs, ... }: +{ + microvm.stateDir = "/var/lib/microvms"; + microvm.vms = { + authentik = { + flake = inputs.self; + updateFlake = "github:gshipunov/nix-config/master"; + }; + }; +} |
