diff options
author | Robert Hensing <robert@roberthensing.nl> | 2021-05-04 16:28:31 +0200 |
---|---|---|
committer | Robert Hensing <robert@roberthensing.nl> | 2021-05-04 16:28:31 +0200 |
commit | 4abd56732e78a1aacf800ef6d77036326b7861b5 (patch) | |
tree | 11e311330e2a8c430476cb0ce86ba65291973d6e /nixos/modules/services/continuous-integration/hercules-ci-agent | |
parent | a1b341da7e7ad76105c4dc02b495d64984f71266 (diff) | |
download | nixpkgs-4abd56732e78a1aacf800ef6d77036326b7861b5.tar nixpkgs-4abd56732e78a1aacf800ef6d77036326b7861b5.tar.gz nixpkgs-4abd56732e78a1aacf800ef6d77036326b7861b5.tar.bz2 nixpkgs-4abd56732e78a1aacf800ef6d77036326b7861b5.tar.lz nixpkgs-4abd56732e78a1aacf800ef6d77036326b7861b5.tar.xz nixpkgs-4abd56732e78a1aacf800ef6d77036326b7861b5.tar.zst nixpkgs-4abd56732e78a1aacf800ef6d77036326b7861b5.zip |
nixos/hercules-ci-agent: Set default concurrency to auto
Diffstat (limited to 'nixos/modules/services/continuous-integration/hercules-ci-agent')
-rw-r--r-- | nixos/modules/services/continuous-integration/hercules-ci-agent/common.nix | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/nixos/modules/services/continuous-integration/hercules-ci-agent/common.nix b/nixos/modules/services/continuous-integration/hercules-ci-agent/common.nix index 9f9b86ee61c..c6f743a71d4 100644 --- a/nixos/modules/services/continuous-integration/hercules-ci-agent/common.nix +++ b/nixos/modules/services/continuous-integration/hercules-ci-agent/common.nix @@ -37,15 +37,22 @@ let description = '' Number of tasks to perform simultaneously. - A task is a single derivation build or an evaluation. + A task is a single derivation build, an evaluation or an effect run. 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. + + The optimal value depends on the resource consumption characteristics of your workload, + including memory usage and in-task parallelism. This is typically determined empirically. + + When scaling, it is generally better to have a double-size machine than two machines, + because each split of resources causes inefficiencies; particularly with regards + to build latency because of extra downloads. ''; - type = types.int; - default = 4; + type = types.either types.ints.positive (types.enum [ "auto" ]); + default = "auto"; }; workDirectory = mkOption { description = '' |