nixos/networkd-dispatcher: add warning when useNetworkd is not enabled
networkd-dispatcher is driven by systemd-networkd events, so enabling the module without `networking.useNetworkd = true` leaves configured scripts unrun with no indication of why. Warn at evaluation time to make the misconfiguration obvious. (See #538523)
This commit is contained in:
@@ -93,6 +93,10 @@ in
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
warnings = mkIf (!config.networking.useNetworkd) [
|
||||
"services.networkd-dispatcher will not execute any scripts unless networking.useNetworkd is enabled."
|
||||
];
|
||||
|
||||
systemd = {
|
||||
packages = [ pkgs.networkd-dispatcher ];
|
||||
services.networkd-dispatcher = {
|
||||
|
||||
Reference in New Issue
Block a user