Join our Discord Server

Helm Cheatsheet [ 2024 Updated]

This comprehensive Helm cheatsheet provides all the necessary commands for managing applications using Helm, contextualizing the terminology like Chart, Name, Release, Revision, Repo-name, and DIR. Each section includes the commands along with practical examples and options.

Chart Management

Chart management focuses on creating, validating, and inspecting Helm charts, which act as templates for deploying Kubernetes resources. Use these commands to develop and package your charts or interact with chart repositories.

CommandDescriptionExample Snippet
helm create <name>Creates a chart directory with common files and directories used in a chart.helm create my-chart
helm package <chart-path>Packages a chart into a versioned .tgz archive file.helm package ./my-chart
helm lint <chart>Validates a chart for syntax errors and best practices.helm lint ./my-chart
helm show all <chart>Displays all metadata and configuration for a chart.helm show all stable/nginx
helm show values <chart>Displays the contents of the values.yaml file for a chart.helm show values stable/nginx
helm pull <chart>Downloads a chart from a repository.helm pull stable/nginx
helm pull <chart> --untarDownloads and extracts a chart to a directory.helm pull stable/nginx --untar=true
helm dependency list <chart>Lists dependencies for a chart.helm dependency list ./my-chart

Install and Uninstall Applications

These commands are used to deploy applications into a Kubernetes cluster using Helm charts. You can customize deployments with values or simulate installations for testing.

CommandDescriptionExample Snippet
helm install <name> <chart>Installs a chart and names the release.helm install my-release stable/nginx
helm install <name> <chart> --namespace <namespace>Installs a chart in a specific namespace.helm install my-release stable/nginx --namespace web-app
helm install <name> <chart> --set key=valSets values via the command line during installation.helm install my-release stable/nginx --set replicaCount=2
helm uninstall <name>Uninstalls a release and deletes resources.helm uninstall my-release

Upgrade and Rollback Releases

Use these commands to update an existing release with new configurations or rollback to a previous state in case of issues.

CommandDescriptionExample Snippet
helm upgrade <release> <chart>Upgrades an existing release with a new chart or configuration.helm upgrade my-release stable/nginx
helm upgrade <release> <chart> --atomicRolls back automatically if the upgrade fails.helm upgrade my-release stable/nginx --atomic
helm rollback <release> <revision>Rolls back a release to a specific revision.helm rollback my-release 2

Repositories Management

Manage Helm repositories to discover, add, update, and remove chart sources.

CommandDescriptionExample Snippet
helm repo add <repo-name> <url>Adds a repository to Helm.helm repo add stable https://charts.helm.sh/stable
helm repo listLists all added repositories.helm repo list
helm repo updateUpdates local repository cache.helm repo update
helm search repo <keyword>Searches repositories for charts using a keyword.helm search repo nginx

Release Monitoring

These commands allow you to check the status of Helm releases and review their deployment history.

CommandDescriptionExample Snippet
helm listLists all releases in the current namespace.helm list
helm status <release>Displays the status of a release.helm status my-release
helm history <release>Shows the history of a release, including revisions.helm history my-release

Inspecting and Debugging

These commands help you debug issues by providing detailed information about Helm releases and their generated resources.

CommandDescriptionExample Snippet
helm get values <release>Retrieves the values used for a release.helm get values my-release
helm get manifest <release>Displays the Kubernetes manifests generated by a release.helm get manifest my-release
helm get hooks <release>Shows hooks for a release.helm get hooks my-release

Plugin Management

Extend Helm’s functionality using plugins for tasks like comparing manifests (helm-diff) or managing secrets (helm-secrets).

CommandDescriptionExample Snippet
helm plugin install <url>Installs a Helm plugin from a URL or local path.helm plugin install https://github.com/databus23/helm-diff
helm plugin listLists installed Helm plugins.helm plugin list

Advanced Options

Commands for environment configuration, template rendering, and debugging workflows.

CommandDescriptionExample Snippet
helm envPrints environment variables used by Helm.helm env
helm template <chart>Renders a chart into Kubernetes manifests without installing.helm template stable/nginx

This cheatsheet is a one-stop guide for mastering Helm, helping you effectively manage Kubernetes applications with practical examples for real-world scenarios.

Join our Discord Server