Understand your Helm deployment before you apply it.
helm-guard is a CLI tool that analyzes rendered Helm manifests and highlights
potential risks, misconfigurations, and operational concerns before deployment.
It helps DevOps engineers, SREs, and platform teams answer a simple question:
“What exactly will this Helm chart deploy — and is it safe?”
Helm charts can be complex:
- Thousands of lines of
values.yaml - Multiple overrides
- Nested subcharts
- Hidden defaults
Running helm install --dry-run shows raw manifests — but does not:
- Aggregate resource usage
- Highlight Single Points of Failure
- Detect missing probes
- Warn about unsafe container settings
- Summarize networking exposure
helm-guard bridges that gap.
- Uses
helm template - Analyzes actual rendered Kubernetes manifests
- Works with any Helm chart
- Deployments / StatefulSets / DaemonSets
- Replica counts
- Container images
- Resource requests & limits
- Services (ClusterIP / NodePort / LoadBalancer)
- Ingress exposure
- TLS presence
Examples:
image: latest- Missing resource limits
- Missing readiness probes
- Single replica exposed via Ingress
- Privileged containers
- hostNetwork enabled
- Exit with non-zero code on selected severity
- JSON output for pipelines
- Markdown report generation
git clone https://github.com/r3based/helm-guard.git
cd helm-guard
go build -o helm-guard ./cmd/helm-guardRequirements:
- Go 1.21+
- Helm installed and available in
$PATH
helm-guard analyze ./chart -f values.yamlhelm-guard analyze ./chart -f values.yaml -f prod.yamlhelm-guard analyze ./chart -f values.yaml --output jsonhelm-guard analyze ./chart -f values.yaml --fail-on highRendered objects: 12
Workloads:
- api (Deployment)
replicas: 2
image: myapp:1.2.3
cpu: 200m / 500m
memory: 256Mi / 512Mi
Networking:
- Ingress: api.example.com
- Service: ClusterIP
Warnings:
[HIGH] api: Missing readiness probe
[MEDIUM] api: No resource limits defined
helm-guard follows a simple pipeline:
helm template
↓
Parse Kubernetes manifests
↓
Build internal model
↓
Apply rules engine
↓
Generate report
Project structure:
cmd/helm-guard → CLI entrypoint
internal/cli → Cobra commands
internal/helm → Helm rendering
internal/kube → YAML parsing
internal/model → Internal workload model
internal/rules → Risk detection engine
internal/report → Output formatting
- Render-first (no guessing from values.yaml)
- No external data sharing
- Deterministic analysis (no AI, no heuristics)
- CI-friendly
- Extensible rule engine
Contributions are welcome.
To run locally:
go run ./cmd/helm-guard analyze ./chart -f values.yamlPlease:
- Keep rules deterministic
- Add tests for new rules
- Follow Go formatting standards (
go fmt)
GNU License
Created by @r3based
If this tool helps you, consider starring the repository.