ci: add govulncheck workflow to auto-create issues for vulnerabilities#278
Merged
Conversation
Add a new GitHub Actions workflow that: - Runs govulncheck on push to main, nightly (4:30 AM UTC), and manual dispatch - Auto-creates/updates a GitHub issue with a link to the workflow run - Deduplicates by matching existing open issues by title + label - Auto-closes the issue when all vulnerabilities are resolved Design decisions: - Use Taskfile for govulncheck install (matching existing workflow patterns) - Use tee so findings appear in run logs for agents/humans to inspect - Detect findings from JSON content with jq, not exit codes - Validate JSON before deciding no findings (avoid wrongly closing issues) - Use --body-file to avoid shell injection from expression interpolation - Keep issue body simple/static, pointing to workflow run for details - Global concurrency group to prevent issue creation races - Follow existing repo patterns (SHA-pinned actions, emoji names, etc.) Closes #275 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The backticks in the echo statement are intentional markdown formatting, not command substitutions. Add shellcheck disable directive to silence the warning. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Closed
8 tasks
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.
Summary
Adds a new GitHub Actions workflow that runs
govulncheckand automatically creates/updates/closes GitHub issues to track vulnerability findings onmain.Changes
.github/workflows/govulncheck.ymlHow it works
main, nightly at 4:30 AM UTC, and manual dispatchgovulncheck -test -json ./...and detects findings viajqgovulnchecklabel) with a link to the workflow runDesign decisions
teeso findings appear in run logs for agents/humans to inspect-jsonmode)--body-fileinstead of expression interpolation to prevent shell injectionubuntu-24.04,persist-credentials: false, Taskfile, etc.Closes #275