From 5c697b8aea5b292be5f6abc1285cd975bbd8dd68 Mon Sep 17 00:00:00 2001 From: Wolfgang Walther Date: Thu, 7 Aug 2025 16:38:14 +0200 Subject: [PATCH] ci/eval: reduce closure size `procps` pulls in 180 MB of systemd, but busybox also provides `kill`. `busybox` also ships `time`, so no need for that extra dependency. Using `nativeBuildInputs` pulls in all the -dev outputs of the listed packages - which we don't need. We only need to run these tools, thus map to their bin outputs. Brings down the closure size from 500+ MB to 193 MB for the Eval job. This probably saves ~10 seconds for the job. --- ci/eval/compare/default.nix | 3 ++- ci/eval/default.nix | 21 +++++++++++---------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/ci/eval/compare/default.nix b/ci/eval/compare/default.nix index 5807f8ef52f7..81eebcc9adb1 100644 --- a/ci/eval/compare/default.nix +++ b/ci/eval/compare/default.nix @@ -122,7 +122,8 @@ let in runCommand "compare" { - nativeBuildInputs = [ + # Don't depend on -dev outputs to reduce closure size for CI. + nativeBuildInputs = map lib.getBin [ jq (python3.withPackages ( ps: with ps; [ diff --git a/ci/eval/default.nix b/ci/eval/default.nix index 018a5b092526..9887afd5e107 100644 --- a/ci/eval/default.nix +++ b/ci/eval/default.nix @@ -14,10 +14,9 @@ runCommand, writeShellScript, symlinkJoin, - time, - procps, - nix, + busybox, jq, + nix, }: let @@ -48,9 +47,10 @@ let runCommand "attrpaths-superset.json" { src = nixpkgs; - nativeBuildInputs = [ + # Don't depend on -dev outputs to reduce closure size for CI. + nativeBuildInputs = map lib.getBin [ + busybox nix - time ]; } '' @@ -131,11 +131,11 @@ let in runCommand "nixpkgs-eval-${evalSystem}" { - nativeBuildInputs = [ - nix - time - procps + # Don't depend on -dev outputs to reduce closure size for CI. + nativeBuildInputs = map lib.getBin [ + busybox jq + nix ]; env = { inherit evalSystem chunkSize; @@ -206,7 +206,8 @@ let }: runCommand "combined-eval" { - nativeBuildInputs = [ + # Don't depend on -dev outputs to reduce closure size for CI. + nativeBuildInputs = map lib.getBin [ jq ]; }