nixos/modprobe: Added boot.modprobeConfig.useUbuntuModuleBlacklist.

Allowing disable of the Ubuntu blacklist.
This commit is contained in:
Harold
2024-02-21 01:10:32 +00:00
parent 0e74ca98a7
commit 4f1dc4bfb7
+7 -1
View File
@@ -11,6 +11,10 @@ with lib;
default = true;
};
boot.modprobeConfig.useUbuntuModuleBlacklist = mkEnableOption (lib.mdDoc "Ubuntu distro's module blacklist") // {
default = true;
};
boot.blacklistedKernelModules = mkOption {
type = types.listOf types.str;
default = [];
@@ -43,7 +47,9 @@ with lib;
config = mkIf config.boot.modprobeConfig.enable {
environment.etc."modprobe.d/ubuntu.conf".source = "${pkgs.kmod-blacklist-ubuntu}/modprobe.conf";
environment.etc."modprobe.d/ubuntu.conf" = mkIf config.boot.modprobeConfig.useUbuntuModuleBlacklist {
source = "${pkgs.kmod-blacklist-ubuntu}/modprobe.conf";
};
environment.etc."modprobe.d/nixos.conf".text =
''