Merge pull request #259658 from Majiir/fix-networkd-wakeonlan

nixos/network-interfaces-systemd: fix WakeOnLan

authored by

Maximilian Bosch and committed by
GitHub
6998695f 09246068

+10 -2
-2
nixos/modules/tasks/network-interfaces-scripted.nix
··· 61 61 MACAddress = i.macAddress; 62 62 } // optionalAttrs (i.mtu != null) { 63 63 MTUBytes = toString i.mtu; 64 - } // optionalAttrs (i.wakeOnLan.enable == true) { 65 - WakeOnLan = concatStringsSep " " i.wakeOnLan.policy; 66 64 }; 67 65 }; 68 66 in listToAttrs (map createNetworkLink interfaces);
+10
nixos/modules/tasks/network-interfaces.nix
··· 1463 1463 ] 1464 1464 ++ bridgeStp; 1465 1465 1466 + # Wake-on-LAN configuration is shared by the scripted and networkd backends. 1467 + systemd.network.links = pipe interfaces [ 1468 + (filter (i: i.wakeOnLan.enable)) 1469 + (map (i: nameValuePair "40-${i.name}" { 1470 + matchConfig.OriginalName = i.name; 1471 + linkConfig.WakeOnLan = concatStringsSep " " i.wakeOnLan.policy; 1472 + })) 1473 + listToAttrs 1474 + ]; 1475 + 1466 1476 # The network-interfaces target is kept for backwards compatibility. 1467 1477 # New modules must NOT use it. 1468 1478 systemd.targets.network-interfaces =