Files
nixpkgs/nixos/modules/system
Val Packett 313fa9dc99 nixos/top-level: fix cutoffPackages without initialRamdisk
In systems without initrd (e.g. containers) that also use system.replaceDependencies, we'd get:

error: attribute 'initialRamdisk' missing
at /nix/store/8vfhnwmmzqqzy97q9c5m4bzyaqqf63zy-source/nixos/modules/system/activation/top-level.nix:286:21:
   285|       cutoffPackages = mkOption {
   286|         default = [ config.system.build.initialRamdisk ];
      |                     ^

Make that initialRamdisk reference conditional on the initrd being enabled.
2025-09-18 18:59:45 -03:00
..