Merge pull request #112637 from hercules-ci/hercules-ci-agent-maintenance
nixos/hercules-ci-agent: maintenance
This commit is contained in:
commit
075e1f7ee4
@ -7,7 +7,6 @@ Platform-specific code is in the respective default.nix files.
|
||||
*/
|
||||
|
||||
{ config, lib, options, pkgs, ... }:
|
||||
|
||||
let
|
||||
inherit (lib)
|
||||
filterAttrs
|
||||
@ -36,10 +35,14 @@ let
|
||||
};
|
||||
concurrentTasks = mkOption {
|
||||
description = ''
|
||||
Number of tasks to perform simultaneously, such as evaluations, derivations.
|
||||
Number of tasks to perform simultaneously.
|
||||
|
||||
You must have a total capacity across agents of at least 2 concurrent tasks on <literal>x86_64-linux</literal>
|
||||
to allow for import from derivation.
|
||||
A task is a single derivation build or an evaluation.
|
||||
At minimum, you need 2 concurrent tasks for <literal>x86_64-linux</literal>
|
||||
in your cluster, to allow for import from derivation.
|
||||
|
||||
<literal>concurrentTasks</literal> can be around the CPU core count or lower if memory is
|
||||
the bottleneck.
|
||||
'';
|
||||
type = types.int;
|
||||
default = 4;
|
||||
@ -85,13 +88,14 @@ let
|
||||
};
|
||||
};
|
||||
|
||||
# TODO (2022) remove
|
||||
# TODO (roberth, >=2022) remove
|
||||
checkNix =
|
||||
if !cfg.checkNix
|
||||
then ""
|
||||
else if lib.versionAtLeast config.nix.package.version "2.3.10"
|
||||
then ""
|
||||
else pkgs.stdenv.mkDerivation {
|
||||
else
|
||||
pkgs.stdenv.mkDerivation {
|
||||
name = "hercules-ci-check-system-nix-src";
|
||||
inherit (config.nix.package) src patches;
|
||||
configurePhase = ":";
|
||||
|
@ -7,9 +7,7 @@ Code that is shared with nix-darwin goes in common.nix.
|
||||
*/
|
||||
|
||||
{ pkgs, config, lib, ... }:
|
||||
|
||||
let
|
||||
|
||||
inherit (lib) mkIf mkDefault;
|
||||
|
||||
cfg = config.services.hercules-ci-agent;
|
||||
@ -82,4 +80,6 @@ in
|
||||
|
||||
users.groups.hercules-ci-agent = { };
|
||||
};
|
||||
|
||||
meta.maintainers = [ lib.maintainers.roberth ];
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user