diff --git a/nixos/modules/system/boot/kernel.nix b/nixos/modules/system/boot/kernel.nix index 006909fbd0c..64d4c33c965 100644 --- a/nixos/modules/system/boot/kernel.nix +++ b/nixos/modules/system/boot/kernel.nix @@ -230,10 +230,8 @@ in { description = "Load Kernel Modules"; wantedBy = [ "sysinit.target" "multi-user.target" ]; before = [ "sysinit.target" "shutdown.target" ]; - unitConfig = - { DefaultDependencies = "no"; - Conflicts = "shutdown.target"; - }; + conflicts = [ "shutdown.target" ]; + unitConfig.DefaultDependencies = "no"; serviceConfig = { Type = "oneshot"; RemainAfterExit = true; diff --git a/nixos/modules/tasks/kbd.nix b/nixos/modules/tasks/kbd.nix index 9f294a5f93e..1083fb784fc 100644 --- a/nixos/modules/tasks/kbd.nix +++ b/nixos/modules/tasks/kbd.nix @@ -55,9 +55,9 @@ in { description = "Setup Virtual Console"; wantedBy = [ "sysinit.target" "multi-user.target" ]; before = [ "sysinit.target" "shutdown.target" ]; + conflicts = [ "shutdown.target" ]; unitConfig = { DefaultDependencies = "no"; - Conflicts = "shutdown.target"; ConditionPathExists = "/dev/tty1"; }; serviceConfig =