---
name: kubernetes-helm-chart-creator
description: "Produces a minimal, installable Helm chart for one application: Chart.yaml, values.yaml, and templates for the Deployment, Service, and optional Ingress with TLS, ready for helm install. Use when an app needs a Helm chart from scratch with Deployment, Service, and optional Ingress templates driven by values.yaml. Do not use for editing an existing chart or writing raw Kubernetes manifests without Helm. Related topics: coding, kubernetes, helm."
---

# Kubernetes Helm Chart Creator

Produces a minimal, installable Helm chart for one application: Chart.yaml, values.yaml, and templates for the Deployment, Service, and optional Ingress with TLS, ready for helm install.

## When to use

Use this skill when an app needs a Helm chart from scratch with Deployment, Service, and optional Ingress templates driven by values.yaml. Do not use it for editing an existing chart or writing raw Kubernetes manifests without Helm.

## Workflow

1. Ask the user for each input listed below in a single message, skipping any they have already given. Where options are listed, offer them, but accept other answers too.
2. Lay out Chart.yaml, values.yaml, the helpers template, and one template per resource, with ingress.yaml present only when ingress is enabled.
3. Move every tunable into values.yaml and reference it from the templates, so no image, port, or host is hard-coded.
4. Wire the Service selector and the Deployment labels through the same helper, so the Service finds the pods.
5. Add the Ingress host and TLS block from the inputs when enabled, naming the secret and how it is issued.
6. Review the templated output for valid YAML and undefined values so the chart passes helm lint, then deliver the files and the install command.

## Inputs

- **Application name** (free text, e.g. "my-app")
- **Replica count** (number from 1 to 10)
- **Container port** (free text, e.g. "80")
- **Enable ingress** (choose one: Yes, No)
- **Hostname** (free text, e.g. "app.example.com")
- **SSL/TLS enabled** (choose one: Yes, No)

## Output

One fenced code block per chart file headed by its path (Chart.yaml, values.yaml, templates/_helpers.tpl, templates/deployment.yaml, templates/service.yaml, templates/ingress.yaml when enabled), followed by the helm install command.

## Prompt template

Fill the inputs into this template and follow it as the full instruction.

### Kubernetes Helm Chart Creator

Create a Helm chart for my application.

- Application name: {{Application name}}
- Replica count: {{Replica count}}
- Container port: {{Container port}}
- Enable ingress: {{Enable ingress}}
- Hostname: {{Hostname}}
- SSL/TLS enabled: {{SSL/TLS enabled}}

Build the standard chart layout: Chart.yaml, values.yaml, templates/_helpers.tpl, templates/deployment.yaml, templates/service.yaml, and templates/ingress.yaml only when ingress is enabled. Put every tunable in values.yaml (image repository and tag, replica count, container port, service type and port, ingress host, TLS secret name, resources) and reference it from the templates, so nothing is hard-coded. Use the helpers for the full name and the standard labels, and make the Service selector use the same selector labels as the Deployment. Set the Deployment's replica count, container port, and probes from values. When TLS is enabled, add the tls block to the Ingress with a secret name derived from the hostname and mention how to issue the certificate. Make the chart pass helm lint as written: valid YAML after templating and no undefined values. Return each file as its own fenced code block headed by its path, then the helm install command with the values that most often need overriding.

## Pitfalls

- Hard-coding the image tag in the template instead of values.yaml, so every release needs a chart edit.
- Using different label sets for the Deployment and the Service selector, which leaves the Service with no endpoints.
- Emitting an Ingress with a tls block but no secret, which makes the controller serve a default certificate.
