Skip to content

fix: replace flaky kube-linter action with cached manual install#106

Merged
pdodgen-revparts merged 2 commits intomainfrom
fix-kube-lint-flaky-download
Mar 9, 2026
Merged

fix: replace flaky kube-linter action with cached manual install#106
pdodgen-revparts merged 2 commits intomainfrom
fix-kube-lint-flaky-download

Conversation

@pdodgen-revparts
Copy link
Copy Markdown
Contributor

@pdodgen-revparts pdodgen-revparts commented Mar 9, 2026

Summary

  • The stackrox/kube-linter-action@v1 download script intermittently fails due to transient GitHub API errors — it uses curl --silent --fail with set -e and no retry logic, causing silent failures across all repos using this workflow
  • Replaces with gh release download (authenticated, better error handling) and actions/cache to skip the download entirely on cache hits
  • Pins kube-linter to v0.8.1 via KUBE_LINTER_VERSION env var for easy bumping
    https://revolutionparts.atlassian.net/browse/DEVEX-1032

Test plan

  • Merge and verify kube-lint passes on an existing PR in encodium/manage
  • Confirm cache hit on a subsequent run in the same repo

The stackrox/kube-linter-action@v1 download script intermittently fails
due to transient GitHub API errors, with no retry logic and silent
failure (curl --silent --fail + set -e). Replace with gh release
download (authenticated via GH_TOKEN) and actions/cache to avoid
repeated API calls entirely.
@cursor
Copy link
Copy Markdown

cursor bot commented Mar 9, 2026

PR Summary

Low Risk
Low risk CI-only change, but it can affect pipeline reliability if the download or cache key/path is incorrect or if the pinned kube-linter version behaves differently.

Overview
Replaces stackrox/kube-linter-action@v1 with a pinned, manual kube-linter install (KUBE_LINTER_VERSION=0.8.1) using gh release download, then runs ./kube-linter lint against the provided directory.

Adds actions/cache for the kube-linter binary keyed by version to avoid repeated downloads and reduce flakiness from transient GitHub API failures.

Written by Cursor Bugbot for commit 6dc1951. This will update automatically on new commits. Configure here.

@pdodgen-revparts pdodgen-revparts marked this pull request as ready for review March 9, 2026 18:05
@pdodgen-revparts pdodgen-revparts requested a review from a team as a code owner March 9, 2026 18:05
Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

@pdodgen-revparts pdodgen-revparts merged commit c9463aa into main Mar 9, 2026
2 checks passed
@pdodgen-revparts pdodgen-revparts deleted the fix-kube-lint-flaky-download branch March 9, 2026 18:13
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