Skip to content

Commit

Permalink
nixos/tests/networking: fix macvlan tests
Browse files Browse the repository at this point in the history
The range option still needs to be defined in dhcpd4 to be able to give out static IP addresses
  • Loading branch information
chvp committed Jul 26, 2020
1 parent 479db27 commit 8eca34d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions nixos/tests/networking.nix
Expand Up @@ -32,14 +32,14 @@ let
services.dhcpd4 = {
enable = true;
interfaces = map (n: "eth${toString n}") vlanIfs;
extraConfig = ''
'' + flip concatMapStrings vlanIfs (n: ''
extraConfig = flip concatMapStrings vlanIfs (n: ''
subnet 192.168.${toString n}.0 netmask 255.255.255.0 {
option routers 192.168.${toString n}.1;
range 192.168.${toString n}.2 192.168.${toString n}.254;
}
'')
;
machines = lib.flip map vlanIfs (vlan:
machines = flip map vlanIfs (vlan:
{
hostName = "client${toString vlan}";
ethernetAddress = qemu-flags.qemuNicMac vlan 1;
Expand Down

0 comments on commit 8eca34d

Please sign in to comment.