diff --git a/nixos/modules/virtualisation/containers.nix b/nixos/modules/virtualisation/containers.nix index 08c234b9413..a0238277f5d 100644 --- a/nixos/modules/virtualisation/containers.nix +++ b/nixos/modules/virtualisation/containers.nix @@ -189,9 +189,13 @@ in "/nix/var/nix/gcroots/per-container/$INSTANCE" if [ "$PRIVATE_NETWORK" = 1 ]; then - extraFlags="--network-veth" + extraFlags+=" --network-veth" fi + for iface in $MACVLANS; do + extraFlags+=" --network-macvlan=$iface" + done + # If the host is 64-bit and the container is 32-bit, add a # --personality flag. ${optionalString (config.nixpkgs.system == "x86_64-linux") ''