add automatic system upgrades

This commit is contained in:
RootHost-Stormwind
2025-01-13 01:30:15 +01:00
parent 87ad1613bb
commit 4f3c9ceb7a
2 changed files with 14 additions and 0 deletions

13
auto-upgrade.nix Normal file
View File

@@ -0,0 +1,13 @@
{ config, ... }:
{
# Rebuild once a day to automatically apply security patches
system.autoUpgrade.enable = true;
nix.optimise.automatic = true;
nix.gc = {
automatic = true;
dates = "daily";
options = "--delete-older-than 30d";
};
}

View File

@@ -19,6 +19,7 @@ in
./user/stormwind/master.nix
./sshd.nix
./tailscale.nix
./auto-upgrade.nix
];
# This value determines the NixOS release from which the default