meow
This commit is contained in:
parent
dee4fdfc60
commit
a1da207bc2
2 changed files with 44 additions and 15 deletions
|
|
@ -8,7 +8,10 @@
|
|||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
crew_interface = "eno1np0";
|
||||
alien_interface = "eno2np1";
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
# Include the results of the hardware scan.
|
||||
|
|
@ -28,21 +31,26 @@
|
|||
# 192.168.42.5/24
|
||||
# gw 192.168.42.1
|
||||
|
||||
# Static IP for eno2np1
|
||||
systemd.network.networks."eno2np1" = {
|
||||
matchConfig.Name = "eno2np1";
|
||||
networkConfig = {
|
||||
Address = "192.168.42.144/24";
|
||||
Gateway = "192.168.42.1";
|
||||
};
|
||||
networking.interfaces.${alien_interface} = {
|
||||
ipv4.addresses = [
|
||||
{
|
||||
address = "192.168.42.5";
|
||||
prefixLength = 24;
|
||||
}
|
||||
];
|
||||
useDHCP = false; # static IP
|
||||
};
|
||||
|
||||
# Let eno1np0 use DHCP
|
||||
systemd.network.networks."eno1np0" = {
|
||||
matchConfig.Name = "eno1np0";
|
||||
networkConfig = {
|
||||
DHCP = true;
|
||||
};
|
||||
networking.interfaces.${crew_interface} = {
|
||||
useDHCP = false; # bridge slave should not request DHCP
|
||||
};
|
||||
|
||||
networking.bridges.vmbr0 = {
|
||||
interfaces = [ "${crew_interface}" ];
|
||||
};
|
||||
|
||||
networking.interfaces.vmbr0 = {
|
||||
useDHCP = true; # bridge gets IP via DHCP
|
||||
};
|
||||
|
||||
# Set your time zone.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue