Skip to content

ci: skip install scripts when installing test dependencies - #837

Closed
aborovsky wants to merge 1 commit into
nextfrom
ci/test-deps-ignore-scripts
Closed

aborovsky wants to merge 1 commit into
nextfrom
ci/test-deps-ignore-scripts

Conversation

@aborovsky

@aborovsky aborovsky commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

Problem

In the release pipeline the smoke/e2e stage takes about 40 minutes, and the Windows jobs set that time. In run 43882484745 their "Install Dependencies" step took 23-29 minutes. On Linux and macOS the same step takes about a minute. The time goes to npm ci running @brightsec/node-libcurl's install script, which on Windows builds curl and its dependencies from source with vcpkg.

These jobs install the repository's dependencies only to run jest. The CLI under test comes from the release assets, the MSI, Docker Hub or npm i -g. The specs import only axios, axios-retry, cross-spawn and wiremock-captain, and none of the native modules.

Change

Set npm_config_ignore_scripts=true on the four "Install Dependencies" steps in test-cli.yml. npm i -g @brightsec/cli in the npm jobs is a separate step, so it still runs install scripts.

Expected effect

  • The executables (Windows ×2) and msi jobs no longer run the vcpkg build: about 20-25 minutes less each.
  • The npm Windows jobs do not get faster yet. Until now their npm i -g @brightsec/cli reused the vcpkg binary cache that npm ci had filled, so that build now happens in "Install CLI" instead. That goes away once the CLI depends on a node-libcurl release that skips vcpkg when the prebuilt binary is available (fix(windows): run vcpkg only when the prebuilt binary is unavailable node-libcurl#52). After that the release's test stage is limited by the test runs themselves.

Verification

  • Locally: npm_config_ignore_scripts=true npm ci, then all smoke and e2e suites load under jest. Without the install scripts there is no node-libcurl binding.
  • e2e from this branch on development (run 45878304453): all 19 jobs passed. On Windows, "Install Dependencies" took 216-273s, and the executables and msi jobs finished in 5-6 minutes. As expected, the npm Windows jobs still spent 1063s and 1594s in "Install CLI" on the vcpkg build.

The smoke and e2e jobs install the repository's dependencies only to run
jest against the CLI under test, which they download or install separately.
On Windows `npm ci` still ran node-libcurl's install script, whose vcpkg
source build took 20-29 minutes in each Windows test job.
@aborovsky

Copy link
Copy Markdown
Contributor Author

Closing: #836 (node-libcurl 5.2.0-2) removes the vcpkg build from npm ci in the test jobs, so skipping install scripts is no longer needed. In e2e run https://github.com/BrightSec/bright-cli/actions/runs/45915144995 from the #836 branch, without this change, Windows "Install Dependencies" took 220-257s.

@aborovsky aborovsky closed this Nov 27, 2026
@aborovsky
aborovsky deleted the ci/test-deps-ignore-scripts branch November 27, 2026 00:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant