diff options
author | Nikolay Amiantov <ab@fmap.me> | 2016-07-07 00:44:02 +0300 |
---|---|---|
committer | Nikolay Amiantov <ab@fmap.me> | 2016-07-18 13:45:37 +0300 |
commit | 86ad25625f7fb6867e515cb09d1da40834f75a9a (patch) | |
tree | 7dfd3e205b24f818593abba54fb42e7fafdf036e /nixos/modules/system/boot/stage-1.nix | |
parent | 36459f19777c788ee4bdc0506aba713ff650815e (diff) | |
download | nixlib-86ad25625f7fb6867e515cb09d1da40834f75a9a.tar nixlib-86ad25625f7fb6867e515cb09d1da40834f75a9a.tar.gz nixlib-86ad25625f7fb6867e515cb09d1da40834f75a9a.tar.bz2 nixlib-86ad25625f7fb6867e515cb09d1da40834f75a9a.tar.lz nixlib-86ad25625f7fb6867e515cb09d1da40834f75a9a.tar.xz nixlib-86ad25625f7fb6867e515cb09d1da40834f75a9a.tar.zst nixlib-86ad25625f7fb6867e515cb09d1da40834f75a9a.zip |
nixos stage-1: add custom pre failure dialog commands
Diffstat (limited to 'nixos/modules/system/boot/stage-1.nix')
-rw-r--r-- | nixos/modules/system/boot/stage-1.nix | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/nixos/modules/system/boot/stage-1.nix b/nixos/modules/system/boot/stage-1.nix index 56a9c38b8f2b..4b1d3efb4113 100644 --- a/nixos/modules/system/boot/stage-1.nix +++ b/nixos/modules/system/boot/stage-1.nix @@ -208,7 +208,7 @@ let inherit (config.boot) resumeDevice devSize runSize; inherit (config.boot.initrd) checkJournalingFS - preLVMCommands preDeviceCommands postDeviceCommands postMountCommands kernelModules; + preLVMCommands preDeviceCommands postDeviceCommands postMountCommands preFailCommands kernelModules; resumeDevices = map (sd: if sd ? device then sd.device else "/dev/disk/by-label/${sd.label}") (filter (sd: (sd ? label || hasPrefix "/dev/" sd.device) && !sd.randomEncryption) config.swapDevices); @@ -336,6 +336,14 @@ in ''; }; + boot.initrd.preFailCommands = mkOption { + default = ""; + type = types.lines; + description = '' + Shell commands to be executed before the failure prompt is shown. + ''; + }; + boot.initrd.extraUtilsCommands = mkOption { internal = true; default = ""; |