Skip to content

Commit f308ee0

Browse files
committed
hydra-queue-runner: 54b3c935 -> 3e77d1e2
1 parent 511c82d commit f308ee0

File tree

4 files changed

+42
-9
lines changed

4 files changed

+42
-9
lines changed

non-critical-infra/hosts/staging-hydra/hydra.nix

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,13 @@ in
120120

121121
hydra-queue-runner-v2 = {
122122
enable = true;
123-
settings.remoteStoreAddr = [
124-
"s3://nix-cache-staging?secret-key=${config.sops.secrets.signing-key.path}&ls-compression=br&log-compression=br"
125-
];
123+
settings = {
124+
queueTriggerTimerInS = 300;
125+
concurrentUploadLimit = 2;
126+
remoteStoreAddr = [
127+
"s3://nix-cache-staging?secret-key=${config.sops.secrets.signing-key.path}&ls-compression=br&log-compression=br"
128+
];
129+
};
126130
};
127131

128132
nginx = {

non-critical-infra/modules/hydra-queue-builder-v2.nix

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,12 @@ in
9898
default = true;
9999
};
100100

101+
authorizationFile = lib.mkOption {
102+
description = "Path to token authorization file if token auth should be used.";
103+
type = lib.types.nullOf lib.types.path;
104+
default = null;
105+
};
106+
101107
mtls = lib.mkOption {
102108
description = "mtls options";
103109
default = null;
@@ -197,6 +203,10 @@ in
197203
++ lib.optionals (cfg.useSubstitutes != null) [
198204
"--use-substitutes"
199205
]
206+
++ lib.optionals (cfg.authorizationFile != null) [
207+
"--authorization-file"
208+
cfg.authorizationFile
209+
]
200210
++ lib.optionals (cfg.mtls != null) [
201211
"--server-root-ca-cert-path"
202212
cfg.mtls.serverRootCaCertPath

non-critical-infra/modules/hydra-queue-runner-v2.nix

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,21 @@ in
101101
type = lib.types.int;
102102
default = 60;
103103
};
104+
maxConcurrentDownloads = lib.mkOption {
105+
description = "Max count of concurrent downloads per build. Increasing this will increase memory usage of the queue runner.";
106+
type = lib.types.ints.positive;
107+
default = 5;
108+
};
109+
concurrentUploadLimit = lib.mkOption {
110+
description = "Concurrent limit for uploading to s3.";
111+
type = lib.types.ints.positive;
112+
default = 5;
113+
};
114+
tokenListPath = lib.mkOption {
115+
description = "Path to a list of allowed authentication tokens.";
116+
type = lib.types.nullOr lib.types.path;
117+
default = null;
118+
};
104119
};
105120
};
106121
default = { };

non-critical-infra/packages/hydra-queue-runner/default.nix

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@
1313
boost,
1414
}:
1515
let
16-
version = "unstable-2025-08-07";
16+
version = "unstable-2025-08-31";
1717
src = fetchFromGitHub {
1818
owner = "helsinki-systems";
1919
repo = "hydra-queue-runner";
20-
rev = "54b3c9351d2ae10be5c4d1b97cc0f86300cd70ca";
21-
hash = "sha256-gR2DzWkTykM9GdW3Nf/V8eRv68fl3aO+NW0zNPFSRT0=";
20+
rev = "3e77d1e2cd8c35583ab85f4dc5793dfa8046f40a";
21+
hash = "sha256-f2JRtKuQNgk1aONAC106BSrVouNAQ8lO90OvA2s7BAI=";
2222
};
2323
useFetchCargoVendor = true;
24-
cargoHash = "sha256-oNUMmFfts4rjBX0k5mzsxpYA2JqgsRu1nMRFf/2rZa8=";
24+
cargoHash = "sha256-kOEIWPTIOVO352Wce7I6qKpKp3vdPH/8vaVSeafcsUs=";
2525
nativeBuildInputs = [
2626
pkg-config
2727
protobuf
@@ -66,7 +66,9 @@ in
6666
cargoTestFlags = finalAttrs.cargoBuildFlags;
6767

6868
postInstall = ''
69-
wrapProgram $out/bin/queue-runner --prefix PATH : ${lib.makeBinPath [ nixVersions.nix_2_29 ]}
69+
wrapProgram $out/bin/queue-runner \
70+
--prefix PATH : ${lib.makeBinPath [ nixVersions.nix_2_29 ]} \
71+
--set-default JEMALLOC_SYS_WITH_MALLOC_CONF "background_thread:true,narenas:1,tcache:false,dirty_decay_ms:0,muzzy_decay_ms:0,abort_conf:true"
7072
'';
7173

7274
meta = meta // {
@@ -94,7 +96,9 @@ in
9496
cargoTestFlags = finalAttrs.cargoBuildFlags;
9597

9698
postInstall = ''
97-
wrapProgram $out/bin/builder --prefix PATH : ${lib.makeBinPath [ nixVersions.nix_2_29 ]}
99+
wrapProgram $out/bin/builder \
100+
--prefix PATH : ${lib.makeBinPath [ nixVersions.nix_2_29 ]} \
101+
--set-default JEMALLOC_SYS_WITH_MALLOC_CONF "background_thread:true,narenas:1,tcache:false,dirty_decay_ms:0,muzzy_decay_ms:0,abort_conf:true"
98102
'';
99103

100104
meta = meta // {

0 commit comments

Comments
 (0)