nixos/tests/{ferm,networking}: fix eval with networkd

The networking.virtual test does not work with networkd yet, for
multiple reasons:

- network-online.target is not reached, because tun0 and tap0 are
  considered as required for online but _not_ brought up or assigned
  the configured addresses
- the commands later in the test rely on some units from the scripted
  network setup

cc @fpletz networkd exper
cc @globin we looked at this together
This commit is contained in:
Linus Heckemann 2019-10-08 17:09:05 +02:00
parent 5aa4b19946
commit a3a441cd87
2 changed files with 2 additions and 0 deletions

View File

@ -23,6 +23,7 @@ import ./make-test.nix ({ pkgs, ...} : {
networking = {
dhcpcd.enable = false;
useNetworkd = true;
useDHCP = false;
interfaces.eth1.ipv6.addresses = mkOverride 0 [ { address = "fd00::1"; prefixLength = 64; } ];
interfaces.eth1.ipv4.addresses = mkOverride 0 [ { address = "192.168.1.1"; prefixLength = 24; } ];
};

View File

@ -450,6 +450,7 @@ let
name = "Virtual";
machine = {
networking.useNetworkd = networkd;
networking.useDHCP = false;
networking.interfaces.tap0 = {
ipv4.addresses = [ { address = "192.168.1.1"; prefixLength = 24; } ];
ipv6.addresses = [ { address = "2001:1470:fffd:2096::"; prefixLength = 64; } ];