make-disk-image: use modules output of a kernel if present

This is a hotfix that could be reverted if we get:

https://github.com/NixOS/nixpkgs/pull/439178

in.
This commit is contained in:
Jörg Thalheim authored and Jörg Thalheim committed 2025-09-01 13:33:49 +00:00
1 parent bafad29f89
commit a5c4f2ab72
1 file changed
+4 -1
+4 -1
View File
@@ -43,7 +43,10 @@ let
++ (lib.optional configSupportsZfs "zfs")
++ cfg.extraRootModules;
kernel = pkgs.aggregateModules (
[ cfg.kernelPackages.kernel ]
[
cfg.kernelPackages.kernel
]
++ lib.optional (cfg.kernelPackages.kernel ? modules) cfg.kernelPackages.kernel.modules
++ lib.optional (
lib.elem "zfs" cfg.extraRootModules || configSupportsZfs
) cfg.kernelPackages.${config.boot.zfs.package.kernelModuleAttribute}