Working bridge configuration using systemd-networkd
This commit is contained in:
parent
c790a14db1
commit
7bce6df38b
1 changed files with 28 additions and 5 deletions
|
@ -36,16 +36,39 @@
|
||||||
|
|
||||||
services.proxmox-ve = {
|
services.proxmox-ve = {
|
||||||
enable = true;
|
enable = true;
|
||||||
ipAddress = "192.168.122.42";
|
ipAddress = "192.168.122.71";
|
||||||
|
|
||||||
# Make vmbr0 bridge visible in Proxmox web interface
|
# Make vmbr0 bridge visible in Proxmox web interface
|
||||||
bridges = [ "vmbr0" ];
|
bridges = [ "vmbr0" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
# Actually set up the vmbr0 bridge
|
networking.useDHCP = false;
|
||||||
networking = {
|
|
||||||
bridges.vmbr0.interfaces = [ "enp1s0" ];
|
systemd.network = {
|
||||||
interfaces.vmbr0.useDHCP = lib.mkDefault true;
|
enable = true;
|
||||||
|
|
||||||
|
networks."10-lan" = {
|
||||||
|
matchConfig.Name = [ "enp1s0" ];
|
||||||
|
networkConfig = {
|
||||||
|
Bridge = "vmbr0";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
netdevs."vmbr0" = {
|
||||||
|
netdevConfig = {
|
||||||
|
Name = "vmbr0";
|
||||||
|
Kind = "bridge";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
networks."10-lan-bridge" = {
|
||||||
|
matchConfig.Name = "vmbr0";
|
||||||
|
networkConfig = {
|
||||||
|
IPv6AcceptRA = true;
|
||||||
|
DHCP = "ipv4";
|
||||||
|
};
|
||||||
|
linkConfig.RequiredForOnline = "routable";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# This option defines the first version of NixOS you have installed on this particular machine,
|
# This option defines the first version of NixOS you have installed on this particular machine,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue