Skip to main content

Customizing Helm Behavior

1. Configuring Helm Environment

Configuration Values Description
helm.home ~/.helm Home directory for Helm configuration and cache
helm.repository.cache ~/.helm/repository/cache Cache directory for Helm repositories
helm.repository.config ~/.helm/repository/repositories.yaml File storing Helm repository configuration

Example: Setting Helm Home

export HELM_HOME=/custom/helm/home
helm version

2. Setting Default Namespace

Configuration Values Description
namespace default Default namespace for Helm releases
kube-context default Kubernetes context to use for deployment

Example: Setting Default Namespace

helm install my-release stable/nginx --namespace production

3. Configuring Kubeconfig Path

Configuration Values Description
kubeconfig ~/.kube/config Path to kubeconfig file for Kubernetes access
kube-context default Kubernetes context to use for deployment

Example: Using Custom Kubeconfig

helm install my-release stable/nginx --kubeconfig /path/to/kubeconfig

4. Setting Repository Cache

Configuration Values Description
repository.cache ~/.helm/repository/cache Directory to cache Helm repository metadata
repository.config ~/.helm/repository/repositories.yaml File storing Helm repository configuration

Example: Clearing Repository Cache

helm repo remove my-repo
helm repo add my-repo https://my.repo.com
helm repo update

5. Configuring Plugins Path

Configuration Values Description
plugins.path ~/.helm/plugins Directory to store Helm plugins
plugins.enabled false Enable or disable plugin support

Example: Installing Plugin

helm plugin install https://github.com/example/plugin

6. Setting Registry Config

Configuration Values Description
registry.config ~/.helm/registry.json File storing registry configuration for OCI charts
registry.credentials ~/.helm/credentials.json Credentials for OCI registry access

Example: Using Registry Config

{
  "registry": {
    "my-registry.com": {
      "username": "user",
      "password": "pass"
    }
  }
}

7. Enabling Experimental Features

Configuration Values Description
experimental false Enable experimental Helm features
experimental.features [] List of experimental features to enable

Example: Enabling Experimental Feature

helm install my-release stable/nginx --set experimental.feature=true

8. Configuring Max History

Configuration Values Description
history.max 10 Maximum number of release history entries to keep
history.max.age 30d Maximum age of release history entries to keep

Example: Setting Max History

helm install my-release stable/nginx --set history.max=5

9. Setting Debug Output

Configuration Values Description
debug false Enable debug logging output
verbose false Enable verbose output

Example: Using Debug Mode

helm install my-release stable/nginx --debug

10. Using Custom Configuration

Configuration Values Description
config.file ~/.helm/config.yaml Path to custom Helm configuration file
config.values [] List of configuration values to override

Example: Custom Configuration File

debug: true
namespace: production
history:
  max: 5

Was this article helpful?