-
Notifications
You must be signed in to change notification settings - Fork 0
Feat/delete unessecary #3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
WalkthroughThe CI workflow's Helm manifest validation step using kubeconform is removed. A new standalone Bash script for Helm chart linting is introduced, which performs linting checks with strict mode and appropriate error handling. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Possibly related PRs
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
scripts/helm_lint.sh (1)
6-18: Consider validating chart directory existence before linting.The script runs helm lint directly without first verifying the chart directory exists. This could result in a confusing helm error message rather than a clear diagnostic.
CHART_DIR="${1:-./helm}" echo "Running helm lint for chart directory: ${CHART_DIR}" +if [[ ! -d "${CHART_DIR}" ]]; then + echo "chart directory not found: ${CHART_DIR}" >&2 + exit 1 +fi + if ! command -v helm >/dev/null 2>&1; then
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
.github/workflows/ci-kind-deploy.yml(0 hunks)scripts/helm_lint.sh(1 hunks)
💤 Files with no reviewable changes (1)
- .github/workflows/ci-kind-deploy.yml
🧰 Additional context used
🪛 GitHub Actions: CI - Kind Helm PR workflow
scripts/helm_lint.sh
[error] 1-1: Permission denied while attempting to execute script './scripts/helm_lint.sh ./helm'. Ensure the script is executable (chmod +x scripts/helm_lint.sh). Process exited with code 126.
| #!/usr/bin/env bash | ||
| # Lint a Helm chart directory. Exits non-zero on failure. | ||
|
|
||
| set -euo pipefail | ||
|
|
||
| CHART_DIR="${1:-./helm}" | ||
|
|
||
| echo "Running helm lint for chart directory: ${CHART_DIR}" | ||
|
|
||
| if ! command -v helm >/dev/null 2>&1; then | ||
| echo "helm is required but not found in PATH" >&2 | ||
| exit 2 | ||
| fi | ||
|
|
||
| helm lint "${CHART_DIR}" \ | ||
| || { echo "helm lint failed" >&2; exit 1; } | ||
|
|
||
| echo "helm lint succeeded for ${CHART_DIR}" No newline at end of file |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Script is not executable—add execute permissions.
The pipeline failure (exit code 126) indicates the script lacks execute permissions. This is a blocker preventing the script from running.
Add execute permissions by running:
chmod +x scripts/helm_lint.shOr include this change in the PR by adding it to .gitattributes or committing with execute permissions set in git:
git update-index --chmod=+x scripts/helm_lint.sh🧰 Tools
🪛 GitHub Actions: CI - Kind Helm PR workflow
[error] 1-1: Permission denied while attempting to execute script './scripts/helm_lint.sh ./helm'. Ensure the script is executable (chmod +x scripts/helm_lint.sh). Process exited with code 126.
🤖 Prompt for AI Agents
In scripts/helm_lint.sh around lines 1 to 18, the script file lacks execute
permissions causing the pipeline to fail with exit code 126; fix by making the
file executable in the repo — run chmod +x scripts/helm_lint.sh locally and
commit the permission change, or use git update-index --chmod=+x
scripts/helm_lint.sh before committing so the executable bit is recorded
(alternatively ensure your CI patches set the executable bit or add appropriate
.gitattributes config).
Summary by CodeRabbit