feat(networking): Add a bridge to connect VMs to the world

This commit is contained in:
sinavir 2024-10-17 17:54:54 +02:00
parent 492fe550d9
commit 3c445ab4c7
3 changed files with 27 additions and 3 deletions

View file

@ -8,12 +8,13 @@ lib.extra.mkConfig {
enabledServices = [
# INFO: This list needs to stay sorted alphabetically
# Machine learning API machine
"microvm-ml01"
"microvm-router01"
# "microvm-ml01"
# "microvm-router01"
"nvidia-tesla-k80"
"ollama"
"whisper"
"proxmox"
"networking"
];
extraConfig = {

View file

@ -0,0 +1,22 @@
{
systemd.networknetworks = {
"10-eno1" = {
matchConfig.Name = [ "eno1" ];
networkConfig = {
Bridge = "vmbr0";
};
};
"10-vmbr0" = {
matchConfig.Name = "vmbr0";
linkConfig.RequiredForOnline = "routable";
};
};
systemd.network.netdevs."vmbr0" = {
netdevConfig = {
Name = "vmbr0";
Kind = "bridge";
};
};
}

View file

@ -31,7 +31,8 @@
krz01 = {
interfaces = {
eno1 = {
# see also machines/krz01/networking.nix
vmbr0 = {
ipv4 = [
{
address = "129.199.146.21";