style(ops/nevsky): centralise depot services in a config block

Change-Id: I46ceb8fdbcb49e98772cb272a7b775761f9d1ed0
Reviewed-on: https://cl.tvl.fyi/c/depot/+/13072
Reviewed-by: sterni <sternenseemann@systemli.org>
Tested-by: BuildkiteCI
This commit is contained in:
Vincent Ambo 2025-02-01 23:51:13 +03:00 committed by tazjin
parent 899142ed2c
commit 119df03a50

View file

@ -246,20 +246,22 @@ in
useRoutingFeatures = "both"; useRoutingFeatures = "both";
}; };
services.depot = {
# Run a Harmonia binary cache. # Run a Harmonia binary cache.
# #
# TODO(tazjin): switch to upstream module after fix for Nix 2.3 # TODO(tazjin): switch to upstream module after fix for Nix 2.3
services.depot.harmonia = { harmonia = {
enable = true; enable = true;
signKeyPaths = [ (config.age.secretsDir + "/nix-cache-priv") ]; signKeyPaths = [ (config.age.secretsDir + "/nix-cache-priv") ];
settings.bind = "127.0.0.1:6443"; settings.bind = "127.0.0.1:6443";
settings.priority = 50; settings.priority = 50;
}; };
services.depot.builderball.enable = true; builderball.enable = true;
# Automatically collect garbage from the Nix store. # Automatically collect garbage from the Nix store.
services.depot.automatic-gc = { automatic-gc = {
enable = true; enable = true;
interval = "1 hour"; interval = "1 hour";
diskThreshold = 200; # GiB diskThreshold = 200; # GiB
@ -268,10 +270,11 @@ in
}; };
# Run a handful of Buildkite agents to support parallel builds. # Run a handful of Buildkite agents to support parallel builds.
services.depot.buildkite = { buildkite = {
enable = true; enable = true;
agentCount = 16; agentCount = 16;
}; };
};
# Start a ZNC instance which bounces for tvlbot and owothia. # Start a ZNC instance which bounces for tvlbot and owothia.
services.znc = { services.znc = {