32 lines
742 B
Nix
Raw Normal View History

{
config,
inputs,
pkgs,
...
}:
2024-07-07 12:38:55 -04:00
{
systemd = {
services.startup_validation = {
wantedBy = [ "multi-user.target" ];
description = "validates startup";
path = [ pkgs.zfs ];
2024-07-07 12:38:55 -04:00
serviceConfig = {
Type = "oneshot";
2024-07-07 19:47:11 -04:00
Environment = config.sops.secrets."server-validation/webhook".path;
2024-07-07 12:38:55 -04:00
ExecStart = "${inputs.server_tools.packages.x86_64-linux.default}/bin/validate_jeevesjr";
};
};
timers.startup_validation = {
wantedBy = [ "timers.target" ];
timerConfig = {
OnBootSec = "10min";
Unit = "startup_validation.service";
};
};
};
2024-07-07 19:47:11 -04:00
sops = {
defaultSopsFile = ./secrets.yaml;
secrets."server-validation/webhook".owner = "root";
};
2024-07-07 12:38:55 -04:00
}