nixos/kernel: obtain in-tree kernel modules via the modules output

This commit is contained in:
Jared Baur 2025-07-25 15:40:10 -07:00
parent 71a314ae4e
commit ca9040f22c
No known key found for this signature in database

View File

@ -387,7 +387,7 @@ in
(mkIf config.boot.kernel.enable {
system.build = { inherit kernel; };
system.modulesTree = [ kernel ] ++ config.boot.extraModulePackages;
system.modulesTree = [ (lib.getOutput "modules" kernel) ] ++ config.boot.extraModulePackages;
# Not required for, e.g., containers as they don't have their own kernel or initrd.
# They boot directly into stage 2.