Enable hourly maintenance
This commit is contained in:
parent
77841f0ace
commit
80e1a78b0f
|
@ -135,6 +135,7 @@ in
|
||||||
./roles/games.nix
|
./roles/games.nix
|
||||||
./roles/git-sign.nix
|
./roles/git-sign.nix
|
||||||
./roles/hoogle.nix
|
./roles/hoogle.nix
|
||||||
|
./roles/hourly-maintenance.nix
|
||||||
./roles/kassandra.nix
|
./roles/kassandra.nix
|
||||||
./roles/khal.nix
|
./roles/khal.nix
|
||||||
./roles/khard.nix
|
./roles/khard.nix
|
||||||
|
|
17
home-manager/roles/hourly-maintenance.nix
Normal file
17
home-manager/roles/hourly-maintenance.nix
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
{ pkgs, config, ... }:
|
||||||
|
{
|
||||||
|
systemd.user = {
|
||||||
|
services.maintenance = {
|
||||||
|
Unit.Description = "Routine maintenance";
|
||||||
|
Service = {
|
||||||
|
Type = "oneshot";
|
||||||
|
ExecStart = "${config.home.profileDirectory}/bin/maintenance --only-on-update";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
timers.maintenance = {
|
||||||
|
Unit.Description = "Hourly maintenance";
|
||||||
|
Timer.OnCalendar = "hourly";
|
||||||
|
Install.WantedBy = [ "timers.target" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue