monolith: limit system slice to 50% cpu usage

This commit is contained in:
Leonardo Eugênio 2026-03-03 23:19:13 -03:00
parent ff74e9ec4a
commit c625920f2c

View file

@ -50,6 +50,14 @@ in
my.gaming.enable = true; my.gaming.enable = true;
my.nix-ld.enable = true; my.nix-ld.enable = true;
systemd.slices."system" = {
enable = true;
sliceConfig = {
# 50% maximum usage accross 8 cores
CPUQuota = "${toString (8 * 50)}%";
};
};
boot.extraModulePackages = with config.boot.kernelPackages; [ zenpower ]; boot.extraModulePackages = with config.boot.kernelPackages; [ zenpower ];
boot.initrd.kernelModules = [ "amdgpu" ]; boot.initrd.kernelModules = [ "amdgpu" ];