diff --git a/config/common/configuration/nix.nix b/config/common/configuration/nix.nix new file mode 100644 index 0000000..8540329 --- /dev/null +++ b/config/common/configuration/nix.nix @@ -0,0 +1,12 @@ +{ ... }: + +# Configuration options for the nix package manager +{ + nix.gc = { + # Run garbage collection automatically + automatic = true; + # Run it once a week + dates = "weekly"; + options = "--delete-older-than 30d"; + }; +} diff --git a/config/hosts/grondahl/configuration.nix b/config/hosts/grondahl/configuration.nix index d260eca..1545408 100644 --- a/config/hosts/grondahl/configuration.nix +++ b/config/hosts/grondahl/configuration.nix @@ -5,6 +5,7 @@ [ # Include the results of the hardware scan. ./hardware-configuration.nix ./data/secrets/secrets.nix + ../../common/configuration/nix.nix ../../common/services/ssh.nix ../../common/services/tailscale.nix ../../common/users.nix diff --git a/config/hosts/rudiger/configuration.nix b/config/hosts/rudiger/configuration.nix index ba07653..212a48c 100644 --- a/config/hosts/rudiger/configuration.nix +++ b/config/hosts/rudiger/configuration.nix @@ -5,6 +5,7 @@ [ ./hardware-configuration.nix ./data/secrets/secrets.nix + ../../common/configuration/nix.nix ../../common/services/ssh.nix ../../common/services/tailscale.nix ../../common/users.nix diff --git a/config/hosts/wind/configuration.nix b/config/hosts/wind/configuration.nix index bb597df..01ce383 100644 --- a/config/hosts/wind/configuration.nix +++ b/config/hosts/wind/configuration.nix @@ -3,6 +3,7 @@ { imports = [ ./hardware-configuration.nix + ../../common/configuration/nix.nix ../../common/services/ssh.nix ../../common/services/tailscale.nix ../../common/users.nix