system/common: misc nix-related changes

This commit is contained in:
chayleaf 2023-08-12 17:40:51 +07:00
parent aa6fef1d9c
commit 67509d0801

View file

@ -38,7 +38,8 @@ in {
cfg = config.common;
in {
nix = {
channel.enable = false;
# nix.channel.enable is needed for NIX_PATH to work for some reason
# channel.enable = false;
settings = {
allowed-users = [ cfg.mainUsername ];
auto-optimise-store = true;
@ -59,6 +60,8 @@ in {
package = pkgs.nixForNixPlugins;
};
systemd.services.nix-daemon.serviceConfig.LimitSTACKSoft = "infinity";
nix.daemonCPUSchedPolicy = lib.mkDefault "idle";
nix.daemonIOSchedClass = lib.mkDefault "idle";
boot.kernelParams = lib.optionals (cfg.resolution != null) [
"consoleblank=60"
] ++ (lib.optionals (cfg.resolution == "1920x1080") [