Skip to content

ci: fail on high/critical vulnerabilities - #73

Merged
tembleking merged 2 commits into
mainfrom
chore/audit-resolutions
Sep 25, 2026
Merged

tembleking merged 2 commits into
mainfrom
chore/audit-resolutions

Conversation

@tembleking

@tembleking tembleking commented Sep 25, 2026 •

Copy link
Copy Markdown
Member

Martin asked for CI to fail when there are major or critical vulnerabilities. This adds just audit (yarn npm audit --all --recursive --severity high) to the PR workflow.

To start green, two transitive deps are forced with resolutions. Backstage's own ranges don't let yarn reach the fixed versions:

  • js-cookie ^3.0.6: pulled in by react-use, which core-components, catalog-react and core-app-api all depend on. react-use only calls get/set/remove, which work the same in v3, and the plugin doesn't use useCookie.
  • adm-zip ^0.6.1: pulled in by @module-federation/dts-plugin from the Backstage CLI, which pins 0.6.0. Patch bump, dev-only.

Resolutions only affect this repo's lockfile. Apps installing the plugin resolve their own versions. They can be removed once Backstage bumps these upstream.

No version bump, since nothing in the published package changes.

The same check also runs as a pre-commit hook, but only when package.json or yarn.lock change. That way a new upstream advisory doesn't block unrelated commits.

Backstage pulls js-cookie 2.x (via react-use) and adm-zip 0.6.0 (via
module-federation), and their ranges keep yarn from reaching the patched
versions. Resolutions force them so the audit gate starts green.
Catches high/critical advisories locally before CI does. Only runs when
package.json or yarn.lock change, so a new upstream advisory doesn't block
unrelated commits.
@tembleking
tembleking merged commit 8692ee1 into main Sep 25, 2026
2 checks passed
@tembleking
tembleking deleted the chore/audit-resolutions branch September 25, 2026 08:43
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.

2 participants