Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

nixos/modprobe: replace boot.isContainer with boot.modprobeConfig.enable

+6 -1
+4 -1
nixos/modules/system/boot/modprobe.nix
··· 7 ###### interface 8 9 options = { 10 11 boot.blacklistedKernelModules = mkOption { 12 type = types.listOf types.str; ··· 38 39 ###### implementation 40 41 - config = mkIf (!config.boot.isContainer) { 42 43 environment.etc."modprobe.d/ubuntu.conf".source = "${pkgs.kmod-blacklist-ubuntu}/modprobe.conf"; 44
··· 7 ###### interface 8 9 options = { 10 + boot.modprobeConfig.enable = mkEnableOption (lib.mdDoc "modprobe config. This is useful for systemds like containers which do not require a kernel.") // { 11 + default = true; 12 + }; 13 14 boot.blacklistedKernelModules = mkOption { 15 type = types.listOf types.str; ··· 41 42 ###### implementation 43 44 + config = mkIf config.boot.modprobeConfig.enable { 45 46 environment.etc."modprobe.d/ubuntu.conf".source = "${pkgs.kmod-blacklist-ubuntu}/modprobe.conf"; 47
+2
nixos/modules/virtualisation/container-config.nix
··· 8 9 # Disable some features that are not useful in a container. 10 11 boot.kernel.enable = false; 12 13 console.enable = mkDefault false; 14
··· 8 9 # Disable some features that are not useful in a container. 10 11 + # containers don't have a kernel 12 boot.kernel.enable = false; 13 + boot.modprobeConfig.enable = false; 14 15 console.enable = mkDefault false; 16