Limit resources for nixos-upgrade systemd service
This commit is contained in:
parent
2231dc65a9
commit
94c0961cb0
|
@ -1,5 +1,6 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
iosevkaCustom,
|
||||
...
|
||||
|
@ -52,15 +53,19 @@
|
|||
randomizedDelaySec = "15min";
|
||||
flags = [
|
||||
"--accept-flake-config"
|
||||
"--keep-going"
|
||||
"--max-jobs"
|
||||
"1"
|
||||
"--option"
|
||||
"extra-binary-caches"
|
||||
"https://nix.xenia.me.uk"
|
||||
];
|
||||
};
|
||||
};
|
||||
systemd.services = lib.mkIf config.system.autoUpgrade.enable {
|
||||
nixos-upgrade.serviceConfig = {
|
||||
CPUQuota = "75%";
|
||||
CPUWeight = 20;
|
||||
IOWeight = 20;
|
||||
};
|
||||
};
|
||||
boot.loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
|
|
Loading…
Reference in a new issue