diff --git a/configuration.nix b/configuration.nix index 9443fb9..e2ae050 100644 --- a/configuration.nix +++ b/configuration.nix @@ -43,4 +43,13 @@ "30 2 * * * /run/current-system/sw/bin/nfs > /etc/nixos/auto_update.log 2>&1" ]; }; + + # https://nixos.wiki/wiki/Storage_optimization + nix.gc = { + automatic = true; + dates = "weekly"; + options = "--delete-older-than 30d"; + }; + nix.optimise.automatic = true; + nix.optimise.dates = [ "Mon *-*-* 05:00:00" ]; }