diff --git a/features/harmonia/default.nix b/features/harmonia/default.nix index a29a0b5..ec1d9c7 100644 --- a/features/harmonia/default.nix +++ b/features/harmonia/default.nix @@ -43,15 +43,10 @@ path = [ config.nix.package ]; }; - systemd.timers.cache-builder = { - description = "Periodically build all host closures"; - wantedBy = [ "timers.target" ]; - timerConfig = { - OnUnitActiveSec = "15min"; - OnBootSec = "5min"; - Persistent = true; - }; - }; + # restart cache-builder after every nixos switch (non-blocking) + system.activationScripts.cache-builder = lib.stringAfter [ "specialfs" ] '' + ${config.systemd.package}/bin/systemctl restart --no-block cache-builder.service || true + ''; }; }; }