···121121 <literal>gnucash24</literal>.
122122 </para>
123123 </listitem>
124124+ <listitem>
125125+ <para>
126126+ The GRUB specific option <option>boot.loader.grub.extraInitrd</option>
127127+ has been replaced with the generic option
128128+ <option>boot.initrd.secrets</option>. This option creates a secondary
129129+ initrd from the specified files, rather than using a manually created
130130+ initrd file.
131131+ </para>
132132+ </listitem>
124133 </itemizedlist>
125134 </section>
126135
+5-15
nixos/modules/system/boot/loader/grub/grub.nix
···3535 let
3636 efiSysMountPoint = if args.efiSysMountPoint == null then args.path else args.efiSysMountPoint;
3737 efiSysMountPoint' = replaceChars [ "/" ] [ "-" ] efiSysMountPoint;
3838+ initrdSecrets = config.boot.initrd.secrets != {};
3839 in
3940 pkgs.writeText "grub-config.xml" (builtins.toXML
4041 { splashImage = f cfg.splashImage;
···4950 storePath = config.boot.loader.grub.storePath;
5051 bootloaderId = if args.efiBootloaderId == null then "NixOS${efiSysMountPoint'}" else args.efiBootloaderId;
5152 timeout = if config.boot.loader.timeout == null then -1 else config.boot.loader.timeout;
5252- inherit efiSysMountPoint;
5353+ inherit efiSysMountPoint initrdSecrets;
5354 inherit (args) devices;
5455 inherit (efi) canTouchEfiVariables;
5556 inherit (cfg)
5657 version extraConfig extraPerEntryConfig extraEntries forceInstall useOSProber
5757- extraEntriesBeforeNixOS extraPrepareConfig extraInitrd configurationLimit copyKernels
5858+ extraEntriesBeforeNixOS extraPrepareConfig configurationLimit copyKernels
5859 default fsIdentifier efiSupport efiInstallAsRemovable gfxmodeEfi gfxmodeBios;
5960 path = (makeBinPath ([
6061 pkgs.coreutils pkgs.gnused pkgs.gnugrep pkgs.findutils pkgs.diffutils pkgs.btrfs-progs
···284285 '';
285286 };
286287287287- extraInitrd = mkOption {
288288- type = types.nullOr types.path;
289289- default = null;
290290- example = "/boot/extra_initramfs.gz";
291291- description = ''
292292- The path to a second initramfs to be supplied to the kernel.
293293- This ramfs will not be copied to the store, so that it can
294294- contain secrets such as LUKS keyfiles or ssh keys.
295295- This implies that rolling back to a previous configuration
296296- won't rollback the state of this file.
297297- '';
298298- };
299299-300288 useOSProber = mkOption {
301289 default = false;
302290 type = types.bool;
···540528 boot.loader.grub.mirroredBoots = optionals (cfg.devices != [ ]) [
541529 { path = "/boot"; inherit (cfg) devices; inherit (efi) efiSysMountPoint; }
542530 ];
531531+532532+ boot.loader.supportsInitrdSecrets = true;
543533544534 system.build.installBootLoader =
545535 let