nichts/modules/services/locate.mod.nix

23 lines
427 B
Nix
Raw Normal View History

2024-07-23 00:00:26 +02:00
{
config,
lib,
pkgs,
...
}:
let
2025-03-26 19:37:50 +01:00
cfg = config.modules.services.locate;
inherit (lib.modules) mkIf;
inherit (lib.options) mkEnableOption;
in
{
2025-03-26 19:37:50 +01:00
options.modules.services.locate.enable = mkEnableOption "Locate service";
2024-07-23 00:00:26 +02:00
config = mkIf cfg.enable {
environment.systemPackages = [ pkgs.plocate ];
2024-07-23 00:00:26 +02:00
services.locate = {
enable = true;
interval = "hourly";
package = pkgs.plocate;
};
};
}