mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-13 21:50:33 +03:00
nixos: kexec: Disable on non-keexecable systems.
This commit is contained in:
parent
d61a22fb0e
commit
a929301281
1 changed files with 19 additions and 18 deletions
|
@ -1,6 +1,7 @@
|
|||
{ config, pkgs, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
config = lib.mkIf (pkgs.kexectools != null) {
|
||||
environment.systemPackages = [ pkgs.kexectools ];
|
||||
|
||||
systemd.services."prepare-kexec" =
|
||||
|
@ -17,5 +18,5 @@
|
|||
exec kexec --load $p/kernel --initrd=$p/initrd --append="$(cat $p/kernel-params) init=$p/init"
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue