+1
-1
lib/systems/default.nix
+1
-1
lib/systems/default.nix
+24
-7
nixos/modules/system/boot/stage-1.nix
+24
-7
nixos/modules/system/boot/stage-1.nix
·········(cd "$tmp" && find . -print0 | sort -z | cpio -o -H newc -R +0:+0 --reproducible --null) | \···+<listitem><para>The name of one of the predefined compressors, see <filename>pkgs/build-support/kernel/initrd-compressor-meta.nix</filename> for the definitions.</para></listitem>+<listitem><para>A function which, given the nixpkgs package set, returns the path to a compressor tool, e.g. <literal>pkgs: "''${pkgs.pigz}/bin/pigz"</literal></para></listitem>+<listitem><para>(not recommended, because it does not work when cross-compiling) the full path to a compressor tool, e.g. <literal>"''${pkgs.pigz}/bin/pigz"</literal></para></listitem>+description = "Arguments to pass to the compressor for the initrd image, or null to use the compressor's defaults.";
+1
nixos/tests/all-tests.nix
+1
nixos/tests/all-tests.nix
···
+35
nixos/tests/initrd-secrets.nix
+35
nixos/tests/initrd-secrets.nix
···
+53
pkgs/build-support/kernel/initrd-compressor-meta.nix
+53
pkgs/build-support/kernel/initrd-compressor-meta.nix
···
+77
-16
pkgs/build-support/kernel/make-initrd.nix
+77
-16
pkgs/build-support/kernel/make-initrd.nix
···+compressorName = fullCommand: builtins.elemAt (builtins.match "([^ ]*/)?([^ ]+).*" fullCommand) 1;+# This can also be a function which takes a package set and returns the path to the compressor,+else if ! builtins.hasContext compressor && builtins.hasAttr compressor compressors then compressors.${compressor}.executable+, _compressorArgsReal ? if compressorArgs == null then _compressorMeta.defaultArgs or [] else compressorArgs+# See https://gitlab.denx.de/u-boot/u-boot/-/blob/9bfb567e5f1bfe7de8eb41f8c6d00f49d2b9a426/common/image.c#L81-106 for a list.+# See https://gitlab.denx.de/u-boot/u-boot/-/blob/9bfb567e5f1bfe7de8eb41f8c6d00f49d2b9a426/common/image.c#L195-204 for a list.······
+7
-4
pkgs/build-support/kernel/make-initrd.sh
+7
-4
pkgs/build-support/kernel/make-initrd.sh
···-(cd root && find * -print0 | sort -z | cpio -o -H newc -R +0:+0 --reproducible --null | $compressor >> $out/initrd)+(cd root && find * .[^.*] -print0 | sort -z | cpio -o -H newc -R +0:+0 --reproducible --null | eval -- $compress >> "$out/initrd")+mkimage -A $uInitrdArch -O linux -T ramdisk -C "$uInitrdCompression" -d $out/initrd"$extension" $out/initrd.img