[MINOR] Add daily npm audit remediation workflow - #5390
Draft
jongyoul wants to merge 1 commit into
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is this PR for?
Add a daily and manually dispatchable workflow that detects high/critical npm audit failures in
zeppelin-web-angular/projects/zeppelin-reactand prepares a validated lockfile-only remediation PR.The workflow never pushes to
masterand never merges a PR. After all checks pass, it writes only to the dedicatedautomation/npm-audit-fix-zeppelin-reactbranch and opens or updates a draft PR.Duplicate prevention is content-based:
The write job is separated from the read-only preparation job. It runs only for scheduled/manual events in
apache/zeppelin, and only after all of these safeguards pass:npm audit fix --package-lock-only --ignore-scriptschanges exactly the React lockfile and never uses--force;What type of PR is it?
Improvement
Todos
actionlint.What is the Jira issue?
N/A for this draft. A Jira can be created before marking the PR ready if required.
How should this be tested?
The current
masterlockfile was tested with Node 22 and npm 10.9.4 using the same sequence as the workflow:zeppelin-react/package-lock.jsonchanged;actionlintv1.7.12, andgit diff --check: passed.For generated PRs, GitHub documents that
pull_requestchecks created throughGITHUB_TOKENstart in an approval-required state. A maintainer can approve those runs; the remediation workflow also completes audit/lint/test/build before creating the PR. See GitHub'sGITHUB_TOKENdocumentation.Screenshots (if appropriate)
N/A
Questions: