diff options
Diffstat (limited to 'hosts/common/core/nix.nix')
-rw-r--r-- | hosts/common/core/nix.nix | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/hosts/common/core/nix.nix b/hosts/common/core/nix.nix index c6279dc..3c798ae 100644 --- a/hosts/common/core/nix.nix +++ b/hosts/common/core/nix.nix @@ -1,36 +1,11 @@ { inputs, lib, ... }: - -let - build-tmp = "/var/tmp"; -in { - +{ nix = { settings = { auto-optimise-store = lib.mkDefault true; - build-dir = build-tmp; experimental-features = [ "nix-command" "flakes" ]; trusted-users = [ "root" "@wheel" ]; warn-dirty = false; }; - - # Garbage Collection - gc = { - automatic = true; - dates = "weekly"; - options = "--delete-older-than 30d"; - persistent = true; - randomizedDelaySec = "14m"; - }; - - }; - - systemd = { - services."nix-daemon".environment.TMPDIR = build-tmp; - user.services."nix-gc" = { - description = "Garbage collection for user profiles"; - script = "/run/current-system/sw/bin/nix-collect-garbage --delete-older-than 30d"; - startAt = "daily"; - }; }; - } |