# helm lint: Command Reference for CI/CD

> Reference for helm lint: validate a chart for structural and best-practice issues before deploy, strict mode, value overrides, and a CI gate example.

Source: https://latchkey.dev/learn/command-reference/helm-lint-command-cli-reference  
Updated: 2026-06-26

Validate a chart before it ever reaches a cluster.

helm lint examines a chart for structural problems and best-practice violations. It is the cheapest first gate in a chart pipeline, catching errors before any render or deploy. This reference covers its flags and CI use.

## Common flags and usage

- lint <chart-dir>: check a chart for issues
- --strict: treat warnings as errors (fail the build on warnings)
- -f values.yaml / --set k=v: lint with specific values
- --quiet: only surface errors, suppress info messages
- Exits non-zero when it finds errors (or warnings under --strict)

## Example

```shell
helm lint ./charts/web --strict \
  -f ./charts/web/values-prod.yaml
```

## In CI

Run lint --strict as an early PR gate so chart problems fail fast and cheap, before helm template or any deploy. Lint with the same values file the deploy uses so value-dependent template errors surface here rather than at install time.

## Using this in CI

A runner has no kubeconfig, no cached context, and no interactive auth. Every kubectl invocation in CI needs the context supplied explicitly, and most confusing CI failures here are the command running against the wrong cluster or no cluster at all.

```Terminal
# never rely on the ambient context on a runner
kubectl --context "$KUBE_CONTEXT" -n "$NAMESPACE" get pods

# confirm what you are actually connected to before mutating anything
kubectl config current-context
kubectl cluster-info

# fail fast instead of hanging on an unreachable API server
kubectl --request-timeout=30s get nodes
```

> Always set `--request-timeout` in CI. Without it an unreachable API server hangs until the job times out, which turns a thirty-second failure into a twenty-minute one.

## FAQ

### helm lint: Command Reference for CI/CD?

helm lint examines a chart for structural problems and best-practice violations. It is the cheapest first gate in a chart pipeline, catching errors before any render or deploy. This reference covers its flags and CI use.

### In CI?

Run lint --strict as an early PR gate so chart problems fail fast and cheap, before helm template or any deploy. Lint with the same values file the deploy uses so value-dependent template errors surface here rather than at install time.

---

Latchkey runs CI/CD that repairs its own failures. Agent entry points: https://latchkey.dev/agent.txt, https://latchkey.dev/openapi.json, https://latchkey.dev/llms.txt
