nixos-config/hosts/vm-infra/configuration.nix

48 lines
822 B
Nix
Raw Normal View History

2025-11-03 13:45:59 +01:00
{
2025-11-07 21:11:35 +01:00
inputs,
2025-11-03 13:45:59 +01:00
...
}:
{
# State version
system.stateVersion = "25.05";
# Machine hostname
networking.hostName = "vm-infra";
# Enabled modules
modules = {
profiles.vm.enable = true;
};
# Setup Tayga NAT64
services.tayga = {
enable = true;
ipv4 = {
address = "10.64.0.0";
router = {
address = "10.64.0.1";
};
pool = {
2025-11-07 20:47:22 +01:00
address = "10.64.0.0";
2025-11-03 13:45:59 +01:00
prefixLength = 16;
};
};
2025-11-07 21:30:13 +01:00
ipv6 =
let
ula = inputs.secrets.lab.network.ula.prefixBase;
net = toString inputs.secrets.lab.network.vlan.lab;
in
{
address = "${ula}:${net}::6464";
router = {
address = "64::ff9b::1";
};
pool = {
address = "64:ff9b::";
prefixLength = 96;
};
2025-11-03 13:45:59 +01:00
};
};
}