17 lines
354 B
Nix
17 lines
354 B
Nix
{
|
|
config,
|
|
lib,
|
|
...
|
|
}: {
|
|
options = {
|
|
crony.oom.enable = lib.mkEnableOption "Enable and setup settings for better oom management on a desktop system and nix build.";
|
|
};
|
|
|
|
config = lib.mkIf config.crony.oom.enable {
|
|
nix.settings.max-jobs = 8;
|
|
services.earlyoom = {
|
|
enable = true;
|
|
enableNotifications = true;
|
|
};
|
|
};
|
|
}
|