Automatic NixOS upgrade module

This commit is contained in:
Andrea Ciceri 2024-01-03 18:06:16 +01:00
parent 93da1c9046
commit 05f6a1e7f6
Signed by: aciceri
SSH key fingerprint: SHA256:/AagBweyV4Hlfg9u092n8hbHwD5fcB6A3qhDiDA65Rg
2 changed files with 18 additions and 0 deletions

View file

@ -0,0 +1,17 @@
{
config,
options,
lib,
...
}: {
system.autoUpgrade = {
enable = true;
flake = "github:aciceri/nixfleet#${config.networking.hostName}";
flags =
lib.lists.optional
(builtins.hasAttr "ccrEmacs" options)
["--update-input" "ccrEmacs" "ccrEmacs"];
dates = "daily";
allowReboot = false;
};
}

View file

@ -5,6 +5,7 @@
}: {
imports = fleetModules [
"nix"
"auto-upgrade"
];
hardware.i2c.enable = true;