2024-02-13 07:31:47 +10:00
|
|
|
{ config, ... }:
|
2021-12-24 07:42:09 +01:00
|
|
|
let
|
|
|
|
herculesSecret = {
|
|
|
|
owner = "hercules-ci-agent";
|
|
|
|
sopsFile = ./secrets.yaml;
|
|
|
|
};
|
2023-01-01 15:30:41 +01:00
|
|
|
inherit (config.sops) secrets;
|
2022-08-14 16:49:30 +02:00
|
|
|
in
|
|
|
|
{
|
2021-12-24 07:42:09 +01:00
|
|
|
sops.secrets."binary-caches.json" = herculesSecret;
|
|
|
|
sops.secrets."cluster-join-token.key" = herculesSecret;
|
2023-09-22 08:36:33 +10:00
|
|
|
sops.secrets."hercules-secrets" = herculesSecret;
|
2021-12-24 07:42:09 +01:00
|
|
|
|
|
|
|
services.hercules-ci-agent = {
|
|
|
|
enable = true;
|
|
|
|
settings = {
|
|
|
|
binaryCachesPath = secrets."binary-caches.json".path;
|
|
|
|
clusterJoinTokenPath = secrets."cluster-join-token.key".path;
|
2023-09-22 08:36:33 +10:00
|
|
|
# secrets file is needed for effects
|
|
|
|
secretsJsonPath = secrets."hercules-secrets".path;
|
2021-12-24 07:42:09 +01:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|