Questions tagged [kubernetes-helm]

Helm is a tool for managing packages (i.e. charts) of templated Kubernetes resources.

Helm simplifies deploying a set of related Kubernetes resources by defining a standard directory structure to hold a set of YAML files, by adding a templating system to produce the actual Kubernetes resources, and by allowing prepackaged applications or components to be directly imported or installed.

The Go text/template engine allows values to be filled into Kubernetes YAML files. In a typical chart, templates/database_statefulset.yaml might contain the fragment:

containers:
  - name: mysql
    image: "{{ .Values.image }}:{{ .Values.tag }}"

values.yaml would provide default values for these settings:

image: mysql
tag: latest

When you install the chart, you can provide specific values for these settings.

helm install . --set tag=5.6

This tag is appropriate for most questions about Helm, including questions about the templating system and the command-line tool. It will frequently also be appropriate to tag questions as related, and many questions relate to the more general system. Do not tag questions as ; that is for a different tool.

External links

6042 questions
27
votes
3 answers

Designing Helm charts for microservices based application

I'm currently building an application that is composed of 4 microservices (a, b, c, d). We would like to make Kubernetes Helm part of our CI/CD pipeline. We are at the point where we're discussing how best to define the charts and was wondering was…
CPH
  • 501
  • 1
  • 5
  • 14
27
votes
4 answers

Helm upgrade doesn't pull new container

I Build a simple NodeJS API, pushed the Docker Image to a repo and deployed it to my k8s with Helm install (works perfectly fine). The pullPolicy is Always. Now I want to update the source code and deploy the updated version of my app. I bumped the…
trahloff
  • 607
  • 1
  • 9
  • 17
26
votes
3 answers

Converting docker-compose to a helm chart?

I have a docker-compose file containing 2 images to a security tool I am using. My challenge is to convert it into helm chart consisting of deployment.yaml and service.yaml. The docker-compose looks like this - version: '3' services: …
Pranav Bhatia
  • 440
  • 2
  • 6
  • 10
26
votes
2 answers

Helm Conditional Templates

I found that we can create subcharts and conditionally include them as described here: Helm conditionally install subchart I have just one template that I want conditionally include in my chart but I could not find anything in the docs. Is there…
Eduardo
  • 5,645
  • 4
  • 49
  • 57
26
votes
6 answers

How to pass entire JSON string to Helm chart value?

How can I pass the entire JSON string to a Helm chart value? I have values.yml where the config value should contain entire JSON with a configuration of an application ... config: some JSON here ... and I need to pass this value to a secret…
Kostrahb
  • 709
  • 1
  • 9
  • 21
26
votes
8 answers

How to pass dynamic arguments to a helm chart that runs a job

I'd like to allow our developers to pass dynamic arguments to a helm template (Kubernetes job). Currently my arguments in the helm template are somewhat static (apart from certain values) and look like this Args: --arg1 …
Aaron Bandelli
  • 1,238
  • 2
  • 14
  • 16
26
votes
3 answers

Kubernetes/Helm: any examples with ConfigMap and "binaryData:"?

With Kubernetes 1.10.* we can use binaryData: with ConfigMap and I am trying to combine it with Helm: apiVersion: v1 kind: ConfigMap metadata: name: some_config_map data: text_data: |- {{ .Files.Get "truststores/simple_text_file.txt"…
pb100
  • 736
  • 3
  • 11
  • 20
25
votes
3 answers

How to use imagePullSecrets: [] in Helm 3

Helm 3 imagePullSecrets: [] secrete gives an error. Error: unable to build Kubernetes objects from release manifest: error validating "": error validating data: ValidationError(Deployment.spec.template.spec.imagePullSecrets[0]): invalid type for…
Rajesh Narayanan
  • 281
  • 1
  • 3
  • 6
25
votes
6 answers

WIll "helm upgrade" restart PODS even if they are not affected by upgrade?

My helm chart has some 12 PODS. When I did helm upgrade after changing some values all the PODs are restarted except for one. My question is: Will helm upgrade restart the PODS even if they are not affected by upgrade? Putting it in another way:…
Chandu
  • 1,837
  • 7
  • 30
  • 51
25
votes
2 answers

pass array in Helm values property

I would like to pass array as property in yaml (values file) in Helm. What I tried: Attempt. elasticsearch: uri: "[\"127.0.0.1:9200\",\"127.0.0.2:9200\"]" Error: ReadString: expects " or n, but found [, error found in #10 byte of …
Bartek
  • 2,109
  • 6
  • 29
  • 40
25
votes
5 answers

terraform helm release timeout while waiting for condition

I'm using terraform to provision some resources in azure and I can't seem to get helm to install nginx-ingress because it timeouts waiting for condition helm_release.nginx_ingress: 1 error(s) occurred: helm_release.nginx_ingress: rpc error: code =…
25
votes
4 answers

How to convert k8s yaml to helm chart

Right now I'm deploying applications on k8s using yaml files. Like the one below: apiVersion: v1 kind: Service metadata: name: serviceA namespace: flow spec: ports: - port: 8080 targetPort: 8080 selector: app:…
mchawre
  • 10,744
  • 4
  • 35
  • 57
25
votes
3 answers

How to delete(uninstall) helm chart on specific resource

I have installed redis. The default given name to me is plinking-narwhal. Now I would like to install a service with my assigned name. But first I want to remove the existing one. I had tried deleting them without success. $ kubectl get all NAME …
joe
  • 8,383
  • 13
  • 61
  • 109
25
votes
4 answers

Combining multiple k8s secrets into an env variable

My k8s namespace contains a Secret which is created at deployment time (by svcat), so the values are not known in advance. apiVersion: v1 kind: Secret type: Opaque metadata: name: my-database-credentials data: hostname: ... port: ... …
metacubed
  • 7,031
  • 6
  • 36
  • 65
24
votes
2 answers

Unset/remove default value in helm values.yaml

I have a downloaded file through helm inspect called sftp.yaml I have a parameter in that sftp.yaml file:- sftp: allowedMACs: "hmac-sha2-512" allowedCiphers: aes256-ctr Now if i install the corresponding helm chart after commenting out the…
Ankit Sharma
  • 413
  • 1
  • 4
  • 9