Internal Safety Override
- Status: local-only unless explicitly opted into external access.
- Before using network tools, account connectors, browser automation, or APIs, state the destination, data scope, and credential source.
- Do not transmit repository files, secrets, credentials, or private documents by default.
- Audit categories: network, secrets.
Helm Chart Builder
Production-grade Helm charts. Sensible defaults. Secure by design. No cargo-culting.
Opinionated Helm workflow that turns ad-hoc Kubernetes manifests into maintainable, testable, reusable charts. Covers chart structure, values design, template patterns, dependency management, and security hardening.
Not a Helm tutorial — a set of concrete decisions about how to build charts that operators trust and developers don't fight.
Slash Commands
| Command |
What it does |
/helm:create |
Scaffold a production-ready Helm chart with best-practice structure |
/helm:review |
Analyze an existing chart for issues — missing labels, hardcoded values, template anti-patterns |
/helm:security |
Audit chart for security issues — RBAC, network policies, pod security, secrets handling |
When This Skill Activates
Recognize these patterns from the user:
- "Create a Helm chart for this service"
- "Review my Helm chart"
- "Is this chart secure?"
- "Design a values.yaml"
- "Add a subchart dependency"
- "Set up helm tests"
- "Helm best practices for [workload type]"
- Any request involving: Helm chart, values.yaml, Chart.yaml, templates, helpers, _helpers.tpl, subcharts, helm lint, helm test
If the user has a Helm chart or wants to package Kubernetes resources → this skill applies.
Workflow
/helm:create — Chart Scaffolding
Identify workload type
- Web service (Deployment + Service + Ingress)
- Worker (Deployment, no Service)
- CronJob (CronJob + ServiceAccount)
- Stateful service (StatefulSet + PVC + Headless Service)
- Library chart (no templates, only helpers)
Scaffold chart structure
mychart/
├── Chart.yaml # Chart metadata and dependencies
├── values.yaml # Default configuration
├── values.schema.json # Optional: JSON Schema for values validation
├── .helmignore # Files to exclude from packaging
├── templates/
│ ├── _helpers.tpl # Named templates and helper functions
│ ├── deployment.yaml # Workload resource
│ ├── service.yaml # Service exposure
│ ├── ingress.yaml # Ingress (if applicable)
│ ├── serviceaccount.yaml # ServiceAccount
│ ├── hpa.yaml # HorizontalPodAutoscaler
│ ├── pdb.yaml # PodDisruptionBudget
│ ├── networkpolicy.yaml # NetworkPolicy
│ ├── configmap.yaml # ConfigMap (if needed)
│ ├── secret.yaml # Secret (if needed)
│ ├── NOTES.txt # Post-install usage instructions
│ └── tests/
│ └── test-connection.yaml
└── charts/ # Subcharts (dependencies)
Apply Chart.yaml best practices
METADATA
├── apiVersion: v2 (Helm 3 only — never v1)
├── name: matches directory name exactly
├── version: semver (chart version, not app version)
├── appVersion: application version string
├── description: one-line summary of what the chart deploys
└── type: application (or library for shared helpers)
DEPENDENCIES
├── Pin dependency versions with ~X.Y.Z (patch-level float)
├── Use condition field to make subcharts optional
├── Use alias for multiple instances of same subchart
└── Run helm dependency update after changes
Generate values.yaml with documentation
- Every value has an inline comment explaining purpose and type
- Sensible defaults that work for development
- Override-friendly structure (flat where possible, nested only when logical)
- No hardcoded cluster-specific values (image registry, domain, storage class)
Validate
python3 scripts/chart_analyzer.py mychart/
helm lint mychart/
helm template mychart/ --debug
/helm:review — Chart Analysis
Check chart structure
| Check |
Severity |
Fix |
| Missing _helpers.tpl |
High |
Create helpers for common labels and selectors |
| No NOTES.txt |
Medium |
Add post-install instructions |
| No .helmignore |
Low |
Create one to exclude .git, CI files, tests |
| Missing Chart.yaml fields |
Medium |
Add description, appVersion, maintainers |
| Hardcoded values in templates |
High |
Extract to values.yaml with defaults |
Check template quality
| Check |
Severity |
Fix |
| Missing standard labels |
High |
Use app.kubernetes.io/* labels via _helpers.tpl |
| No resource requests/limits |
Critical |
Add resources section with defaults in values.yaml |
| Hardcoded image tag |
High |
Use {{ .Values.image.repository }}:{{ .Values.image.tag }} |
| No imagePullPolicy |
Medium |
Default to IfNotPresent, overridable |
| Missing liveness/readiness probes |
High |
Add probes with configurable paths and ports |
| No pod anti-affinity |
Medium |
Add preferred anti-affinity for HA |
| Duplicate template code |
Medium |
Extract into named templates in _helpers.tpl |
Check values.yaml quality
python3 scripts/values_validator.py mychart/values.yaml
Generate review report
HELM CHART REVIEW — [chart name]
Date: [timestamp]
CRITICAL: [count]
HIGH: [count]
MEDIUM: [count]
LOW: [count]
[Detailed findings with fix recommendations]
/helm:security — Security Audit
Pod security audit
| Check |
Severity |
Fix |
| No securityContext |
Critical |
Add runAsNonRoot, readOnlyRootFilesystem |
| Running as root |
Critical |
Set runAsNonRoot: true, runAsUser: 1000 |
| Writable root filesystem |
High |
Set readOnlyRootFilesystem: true + emptyDir for tmp |
| All capabilities retained |
High |
Drop ALL, add only specific needed caps |
| Privileged container |
Critical |
Set privileged: false, use specific capabilities |
| No seccomp profile |
Medium |
Set seccompProfile.type: RuntimeDefault |
| allowPrivilegeEscalation true |
High |
Set allowPrivilegeEscalation: false |
RBAC audit
| Check |
Severity |
Fix |
| No ServiceAccount |
Medium |
Create dedicated SA, don't use default |
| automountServiceAccountToken true |
Medium |
Set to false unless pod needs K8s API access |
| ClusterRole instead of Role |
Medium |
Use namespace-scoped Role unless cluster-wide needed |
| Wildcard permissions |
Critical |
Use specific resource names and verbs |
| No RBAC at all |
Low |
Acceptable if pod doesn't need K8s API access |
Network and secrets audit
| Check |
Severity |
Fix |
| No NetworkPolicy |
Medium |
Add default-deny ingress + explicit allow rules |
| Secrets in values.yaml |
Critical |
Use external secrets operator or sealed-secrets |
| No PodDisruptionBudget |
Medium |
Add PDB with minAvailable for HA workloads |
| hostNetwork: true |
High |
Remove unless absolutely required (e.g., CNI plugin) |
| hostPID or hostIPC |
Critical |
Never use in application charts |
Generate security report
SECURITY AUDIT — [chart name]
Date: [timestamp]
CRITICAL: [count]
HIGH: [count]
MEDIUM: [count]
LOW: [count]
[Detailed findings with remediation steps]
Tooling
scripts/chart_analyzer.py
CLI utility for static analysis of Helm chart directories.
Features:
- Chart structure validation (required files, directory layout)
- Template anti-pattern detection (hardcoded values, missing labels, no resource limits)
- Chart.yaml metadata checks
- Standard labels verification (app.kubernetes.io/*)
- Security baseline checks
- JSON and text output
Usage:
# Analyze a chart directory
python3 scripts/chart_analyzer.py mychart/
# JSON output
python3 scripts/chart_analyzer.py mychart/ --output json
# Security-focused analysis
python3 scripts/chart_analyzer.py mychart/ --security
scripts/values_validator.py
CLI utility for validating values.yaml against best practices.
Features:
- Documentation coverage (inline comments)
- Type consistency checks
- Hardcoded secrets detection
- Default value quality analysis
- Structure depth analysis
- Naming convention validation
- JSON and text output
Usage:
# Validate values.yaml
python3 scripts/values_validator.py values.yaml
# JSON output
python3 scripts/values_validator.py values.yaml --output json
# Strict mode (fail on warnings)
python3 scripts/values_validator.py values.yaml --strict
Template Patterns
Pattern 1: Standard Labels (_helpers.tpl)
{{/*
Common labels for all resources.
*/}}
{{- define "mychart.labels" -}}
helm.sh/chart: {{ include "mychart.chart" . }}
app.kubernetes.io/name: {{ include "mychart.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}
{{/*
Selector labels (subset of common labels — must be immutable).
*/}}
{{- define "mychart.selectorLabels" -}}
app.kubernetes.io/name: {{ include "mychart.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}
Pattern 2: Conditional Resources
{{- if .Values.ingress.enabled -}}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ include "mychart.fullname" . }}
labels:
{{- include "mychart.labels" . | nindent 4 }}
{{- with .Values.ingress.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if .Values.ingress.tls }}
tls:
{{- range .Values.ingress.tls }}
- hosts:
{{- range .hosts }}
- {{ . | quote }}
{{- end }}
secretName: {{ .secretName }}
{{- end }}
{{- end }}
rules:
{{- range .Values.ingress.hosts }}
- host: {{ .host | quote }}
http:
paths:
{{- range .paths }}
- path: {{ .path }}
pathType: {{ .pathType }}
backend:
service:
name: {{ include "mychart.fullname" $ }}
port:
number: {{ $.Values.service.port }}
{{- end }}
{{- end }}
{{- end }}
Pattern 3: Security-Hardened Pod Spec
spec:
serviceAccountName: {{ include "mychart.serviceAccountName" . }}
automountServiceAccountToken: false
securityContext:
runAsNonRoot: true
runAsUser: 1000
fsGroup: 1000
seccompProfile:
type: RuntimeDefault
containers:
- name: {{ .Chart.Name }}
securityContext:
allowPrivilegeEscalation: false
readOnlyRootFilesystem: true
capabilities:
drop:
- ALL
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
resources:
{{- toYaml .Values.resources | nindent 8 }}
volumeMounts:
- name: tmp
mountPath: /tmp
volumes:
- name: tmp
emptyDir: {}
Values Design Principles
STRUCTURE
├── Flat over nested (image.tag > container.spec.image.tag)
├── Group by resource (service.*, ingress.*, resources.*)
├── Use enabled: true/false for optional resources
├── Document every key with inline YAML comments
└── Provide sensible development defaults
NAMING
├── camelCase for keys (replicaCount, not replica_count)
├── Boolean keys: use adjectives (enabled, required) not verbs
├── Nested keys: max 3 levels deep
└── Match upstream conventions (image.repository, image.tag, image.pullPolicy)
ANTI-PATTERNS
├── Hardcoded cluster URLs or domains
├── Secrets as default values
├── Empty strings where null is correct
├── Deeply nested structures (>3 levels)
├── Undocumented values
└── values.yaml that doesn't work without overrides
Dependency Management
SUBCHARTS
├── Use Chart.yaml dependencies (not requirements.yaml — Helm 3)
├── Pin versions: version: ~15.x.x (patch float)
├── Use condition: to make optional: condition: postgresql.enabled
├── Use alias: for multiple instances of same chart
├── Override subchart values under subchart name key in values.yaml
└── Run helm dependency update before packaging
LIBRARY CHARTS
├── type: library in Chart.yaml — no templates directory
├── Export named templates only — no rendered resources
├── Use for shared labels, annotations, security contexts
└── Version independently from application charts
Proactive Triggers
Flag these without being asked:
- No _helpers.tpl → Create one. Every chart needs standard labels and fullname helpers.
- Hardcoded image tag in template → Extract to values.yaml. Tags must be overridable.
- No resource requests/limits → Add them. Pods without limits can starve the node.
- Running as root → Add securityContext. No exceptions for production charts.
- No NOTES.txt → Create one. Users need post-install instructions.
- Secrets in values.yaml defaults → Remove them. Use placeholders with comments explaining how to provide secrets.
- No liveness/readiness probes → Add them. Kubernetes needs to know if the pod is healthy.
- Missing app.kubernetes.io labels → Add via _helpers.tpl. Required for proper resource tracking.
Installation
One-liner (any tool)
git clone https://github.com/alirezarezvani/ai-ops-skills.git
cp -r ai-ops-skills/engineering/helm-chart-builder ~/.claude/skills/
Multi-tool install
./scripts/convert.sh --skill helm-chart-builder --tool codex|gemini|cursor|windsurf|openclaw
OpenClaw
clawhub install cs-helm-chart-builder
Related Skills
- senior-devops — Broader DevOps scope (CI/CD, IaC, monitoring). Complementary — use helm-chart-builder for chart-specific work, senior-devops for pipeline and infrastructure.
- docker-development — Container building. Complementary — docker-development builds the images, helm-chart-builder deploys them to Kubernetes.
- ci-cd-pipeline-builder — Pipeline construction. Complementary — helm-chart-builder defines the deployment artifact, ci-cd-pipeline-builder automates its delivery.
- senior-security — Application security. Complementary — helm-chart-builder covers Kubernetes-level security (RBAC, pod security), senior-security covers application-level threats.
1---2name: helm-chart-builder3description: Helm chart development agent skill and plugin for an agent runtime, Codex, an agent runtime, Cursor, OpenClaw — chart scaffolding, values design, template patterns, dependency management, security hardening, and chart testing. Use when: user wants to create or improve Helm charts, design values.yaml files, implement template helpers, audit chart security (RBAC, network policies, pod security), manage subcharts, or run helm lint/test.4license: MIT5---67## Internal Safety Override89- Status: local-only unless explicitly opted into external access.10- Before using network tools, account connectors, browser automation, or APIs, state the destination, data scope, and credential source.11- Do not transmit repository files, secrets, credentials, or private documents by default.12- Audit categories: network, secrets.1314# Helm Chart Builder1516> Production-grade Helm charts. Sensible defaults. Secure by design. No cargo-culting.1718Opinionated Helm workflow that turns ad-hoc Kubernetes manifests into maintainable, testable, reusable charts. Covers chart structure, values design, template patterns, dependency management, and security hardening.1920Not a Helm tutorial — a set of concrete decisions about how to build charts that operators trust and developers don't fight.2122---2324## Slash Commands2526| Command | What it does |27|---------|-------------|28| `/helm:create` | Scaffold a production-ready Helm chart with best-practice structure |29| `/helm:review` | Analyze an existing chart for issues — missing labels, hardcoded values, template anti-patterns |30| `/helm:security` | Audit chart for security issues — RBAC, network policies, pod security, secrets handling |3132---3334## When This Skill Activates3536Recognize these patterns from the user:3738- "Create a Helm chart for this service"39- "Review my Helm chart"40- "Is this chart secure?"41- "Design a values.yaml"42- "Add a subchart dependency"43- "Set up helm tests"44- "Helm best practices for [workload type]"45- Any request involving: Helm chart, values.yaml, Chart.yaml, templates, helpers, _helpers.tpl, subcharts, helm lint, helm test4647If the user has a Helm chart or wants to package Kubernetes resources → this skill applies.4849---5051## Workflow5253### `/helm:create` — Chart Scaffolding54551. **Identify workload type**56 - Web service (Deployment + Service + Ingress)57 - Worker (Deployment, no Service)58 - CronJob (CronJob + ServiceAccount)59 - Stateful service (StatefulSet + PVC + Headless Service)60 - Library chart (no templates, only helpers)61622. **Scaffold chart structure**6364 ```65 mychart/66 ├── Chart.yaml # Chart metadata and dependencies67 ├── values.yaml # Default configuration68 ├── values.schema.json # Optional: JSON Schema for values validation69 ├── .helmignore # Files to exclude from packaging70 ├── templates/71 │ ├── _helpers.tpl # Named templates and helper functions72 │ ├── deployment.yaml # Workload resource73 │ ├── service.yaml # Service exposure74 │ ├── ingress.yaml # Ingress (if applicable)75 │ ├── serviceaccount.yaml # ServiceAccount76 │ ├── hpa.yaml # HorizontalPodAutoscaler77 │ ├── pdb.yaml # PodDisruptionBudget78 │ ├── networkpolicy.yaml # NetworkPolicy79 │ ├── configmap.yaml # ConfigMap (if needed)80 │ ├── secret.yaml # Secret (if needed)81 │ ├── NOTES.txt # Post-install usage instructions82 │ └── tests/83 │ └── test-connection.yaml84 └── charts/ # Subcharts (dependencies)85 ```86873. **Apply Chart.yaml best practices**8889 ```90 METADATA91 ├── apiVersion: v2 (Helm 3 only — never v1)92 ├── name: matches directory name exactly93 ├── version: semver (chart version, not app version)94 ├── appVersion: application version string95 ├── description: one-line summary of what the chart deploys96 └── type: application (or library for shared helpers)9798 DEPENDENCIES99 ├── Pin dependency versions with ~X.Y.Z (patch-level float)100 ├── Use condition field to make subcharts optional101 ├── Use alias for multiple instances of same subchart102 └── Run helm dependency update after changes103 ```1041054. **Generate values.yaml with documentation**106 - Every value has an inline comment explaining purpose and type107 - Sensible defaults that work for development108 - Override-friendly structure (flat where possible, nested only when logical)109 - No hardcoded cluster-specific values (image registry, domain, storage class)1101115. **Validate**112 ```bash113 python3 scripts/chart_analyzer.py mychart/114 helm lint mychart/115 helm template mychart/ --debug116 ```117118### `/helm:review` — Chart Analysis1191201. **Check chart structure**121122 | Check | Severity | Fix |123 |-------|----------|-----|124 | Missing _helpers.tpl | High | Create helpers for common labels and selectors |125 | No NOTES.txt | Medium | Add post-install instructions |126 | No .helmignore | Low | Create one to exclude .git, CI files, tests |127 | Missing Chart.yaml fields | Medium | Add description, appVersion, maintainers |128 | Hardcoded values in templates | High | Extract to values.yaml with defaults |1291302. **Check template quality**131132 | Check | Severity | Fix |133 |-------|----------|-----|134 | Missing standard labels | High | Use `app.kubernetes.io/*` labels via _helpers.tpl |135 | No resource requests/limits | Critical | Add resources section with defaults in values.yaml |136 | Hardcoded image tag | High | Use `{{ .Values.image.repository }}:{{ .Values.image.tag }}` |137 | No imagePullPolicy | Medium | Default to `IfNotPresent`, overridable |138 | Missing liveness/readiness probes | High | Add probes with configurable paths and ports |139 | No pod anti-affinity | Medium | Add preferred anti-affinity for HA |140 | Duplicate template code | Medium | Extract into named templates in _helpers.tpl |1411423. **Check values.yaml quality**143 ```bash144 python3 scripts/values_validator.py mychart/values.yaml145 ```1461474. **Generate review report**148 ```149 HELM CHART REVIEW — [chart name]150 Date: [timestamp]151152 CRITICAL: [count]153 HIGH: [count]154 MEDIUM: [count]155 LOW: [count]156157 [Detailed findings with fix recommendations]158 ```159160### `/helm:security` — Security Audit1611621. **Pod security audit**163164 | Check | Severity | Fix |165 |-------|----------|-----|166 | No securityContext | Critical | Add runAsNonRoot, readOnlyRootFilesystem |167 | Running as root | Critical | Set `runAsNonRoot: true`, `runAsUser: 1000` |168 | Writable root filesystem | High | Set `readOnlyRootFilesystem: true` + emptyDir for tmp |169 | All capabilities retained | High | Drop ALL, add only specific needed caps |170 | Privileged container | Critical | Set `privileged: false`, use specific capabilities |171 | No seccomp profile | Medium | Set `seccompProfile.type: RuntimeDefault` |172 | allowPrivilegeEscalation true | High | Set `allowPrivilegeEscalation: false` |1731742. **RBAC audit**175176 | Check | Severity | Fix |177 |-------|----------|-----|178 | No ServiceAccount | Medium | Create dedicated SA, don't use default |179 | automountServiceAccountToken true | Medium | Set to false unless pod needs K8s API access |180 | ClusterRole instead of Role | Medium | Use namespace-scoped Role unless cluster-wide needed |181 | Wildcard permissions | Critical | Use specific resource names and verbs |182 | No RBAC at all | Low | Acceptable if pod doesn't need K8s API access |1831843. **Network and secrets audit**185186 | Check | Severity | Fix |187 |-------|----------|-----|188 | No NetworkPolicy | Medium | Add default-deny ingress + explicit allow rules |189 | Secrets in values.yaml | Critical | Use external secrets operator or sealed-secrets |190 | No PodDisruptionBudget | Medium | Add PDB with minAvailable for HA workloads |191 | hostNetwork: true | High | Remove unless absolutely required (e.g., CNI plugin) |192 | hostPID or hostIPC | Critical | Never use in application charts |1931944. **Generate security report**195 ```196 SECURITY AUDIT — [chart name]197 Date: [timestamp]198199 CRITICAL: [count]200 HIGH: [count]201 MEDIUM: [count]202 LOW: [count]203204 [Detailed findings with remediation steps]205 ```206207---208209## Tooling210211### `scripts/chart_analyzer.py`212213CLI utility for static analysis of Helm chart directories.214215**Features:**216- Chart structure validation (required files, directory layout)217- Template anti-pattern detection (hardcoded values, missing labels, no resource limits)218- Chart.yaml metadata checks219- Standard labels verification (app.kubernetes.io/*)220- Security baseline checks221- JSON and text output222223**Usage:**224```bash225# Analyze a chart directory226python3 scripts/chart_analyzer.py mychart/227228# JSON output229python3 scripts/chart_analyzer.py mychart/ --output json230231# Security-focused analysis232python3 scripts/chart_analyzer.py mychart/ --security233```234235### `scripts/values_validator.py`236237CLI utility for validating values.yaml against best practices.238239**Features:**240- Documentation coverage (inline comments)241- Type consistency checks242- Hardcoded secrets detection243- Default value quality analysis244- Structure depth analysis245- Naming convention validation246- JSON and text output247248**Usage:**249```bash250# Validate values.yaml251python3 scripts/values_validator.py values.yaml252253# JSON output254python3 scripts/values_validator.py values.yaml --output json255256# Strict mode (fail on warnings)257python3 scripts/values_validator.py values.yaml --strict258```259260---261262## Template Patterns263264### Pattern 1: Standard Labels (_helpers.tpl)265266```yaml267{{/*268Common labels for all resources.269*/}}270{{- define "mychart.labels" -}}271helm.sh/chart: {{ include "mychart.chart" . }}272app.kubernetes.io/name: {{ include "mychart.name" . }}273app.kubernetes.io/instance: {{ .Release.Name }}274app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}275app.kubernetes.io/managed-by: {{ .Release.Service }}276{{- end }}277278{{/*279Selector labels (subset of common labels — must be immutable).280*/}}281{{- define "mychart.selectorLabels" -}}282app.kubernetes.io/name: {{ include "mychart.name" . }}283app.kubernetes.io/instance: {{ .Release.Name }}284{{- end }}285```286287### Pattern 2: Conditional Resources288289```yaml290{{- if .Values.ingress.enabled -}}291apiVersion: networking.k8s.io/v1292kind: Ingress293metadata:294 name: {{ include "mychart.fullname" . }}295 labels:296 {{- include "mychart.labels" . | nindent 4 }}297 {{- with .Values.ingress.annotations }}298 annotations:299 {{- toYaml . | nindent 4 }}300 {{- end }}301spec:302 {{- if .Values.ingress.tls }}303 tls:304 {{- range .Values.ingress.tls }}305 - hosts:306 {{- range .hosts }}307 - {{ . | quote }}308 {{- end }}309 secretName: {{ .secretName }}310 {{- end }}311 {{- end }}312 rules:313 {{- range .Values.ingress.hosts }}314 - host: {{ .host | quote }}315 http:316 paths:317 {{- range .paths }}318 - path: {{ .path }}319 pathType: {{ .pathType }}320 backend:321 service:322 name: {{ include "mychart.fullname" $ }}323 port:324 number: {{ $.Values.service.port }}325 {{- end }}326 {{- end }}327{{- end }}328```329330### Pattern 3: Security-Hardened Pod Spec331332```yaml333spec:334 serviceAccountName: {{ include "mychart.serviceAccountName" . }}335 automountServiceAccountToken: false336 securityContext:337 runAsNonRoot: true338 runAsUser: 1000339 fsGroup: 1000340 seccompProfile:341 type: RuntimeDefault342 containers:343 - name: {{ .Chart.Name }}344 securityContext:345 allowPrivilegeEscalation: false346 readOnlyRootFilesystem: true347 capabilities:348 drop:349 - ALL350 image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"351 imagePullPolicy: {{ .Values.image.pullPolicy }}352 resources:353 {{- toYaml .Values.resources | nindent 8 }}354 volumeMounts:355 - name: tmp356 mountPath: /tmp357 volumes:358 - name: tmp359 emptyDir: {}360```361362---363364## Values Design Principles365366```367STRUCTURE368├── Flat over nested (image.tag > container.spec.image.tag)369├── Group by resource (service.*, ingress.*, resources.*)370├── Use enabled: true/false for optional resources371├── Document every key with inline YAML comments372└── Provide sensible development defaults373374NAMING375├── camelCase for keys (replicaCount, not replica_count)376├── Boolean keys: use adjectives (enabled, required) not verbs377├── Nested keys: max 3 levels deep378└── Match upstream conventions (image.repository, image.tag, image.pullPolicy)379380ANTI-PATTERNS381├── Hardcoded cluster URLs or domains382├── Secrets as default values383├── Empty strings where null is correct384├── Deeply nested structures (>3 levels)385├── Undocumented values386└── values.yaml that doesn't work without overrides387```388389---390391## Dependency Management392393```394SUBCHARTS395├── Use Chart.yaml dependencies (not requirements.yaml — Helm 3)396├── Pin versions: version: ~15.x.x (patch float)397├── Use condition: to make optional: condition: postgresql.enabled398├── Use alias: for multiple instances of same chart399├── Override subchart values under subchart name key in values.yaml400└── Run helm dependency update before packaging401402LIBRARY CHARTS403├── type: library in Chart.yaml — no templates directory404├── Export named templates only — no rendered resources405├── Use for shared labels, annotations, security contexts406└── Version independently from application charts407```408409---410411## Proactive Triggers412413Flag these without being asked:414415- **No _helpers.tpl** → Create one. Every chart needs standard labels and fullname helpers.416- **Hardcoded image tag in template** → Extract to values.yaml. Tags must be overridable.417- **No resource requests/limits** → Add them. Pods without limits can starve the node.418- **Running as root** → Add securityContext. No exceptions for production charts.419- **No NOTES.txt** → Create one. Users need post-install instructions.420- **Secrets in values.yaml defaults** → Remove them. Use placeholders with comments explaining how to provide secrets.421- **No liveness/readiness probes** → Add them. Kubernetes needs to know if the pod is healthy.422- **Missing app.kubernetes.io labels** → Add via _helpers.tpl. Required for proper resource tracking.423424---425426## Installation427428### One-liner (any tool)429```bash430git clone https://github.com/alirezarezvani/ai-ops-skills.git431cp -r ai-ops-skills/engineering/helm-chart-builder ~/.claude/skills/432```433434### Multi-tool install435```bash436./scripts/convert.sh --skill helm-chart-builder --tool codex|gemini|cursor|windsurf|openclaw437```438439### OpenClaw440```bash441clawhub install cs-helm-chart-builder442```443444---445446## Related Skills447448- **senior-devops** — Broader DevOps scope (CI/CD, IaC, monitoring). Complementary — use helm-chart-builder for chart-specific work, senior-devops for pipeline and infrastructure.449- **docker-development** — Container building. Complementary — docker-development builds the images, helm-chart-builder deploys them to Kubernetes.450- **ci-cd-pipeline-builder** — Pipeline construction. Complementary — helm-chart-builder defines the deployment artifact, ci-cd-pipeline-builder automates its delivery.451- **senior-security** — Application security. Complementary — helm-chart-builder covers Kubernetes-level security (RBAC, pod security), senior-security covers application-level threats.