Helm chart to deploy and scale a generic app image

This is a post about a simple helm chart that I have worked on to deploy any generic app image to Kubernetes. The chart is available [here]

It tries to solve the issue of having to manage a set of raw Kubernetes resources(deployment,secrets,hpa) and instead letting helm manage these resources. The chart is generic enough that it should be able to handle most 12-factor compliant app images.

Consider a simple app that I have here –, an image for this application is publicly available on dockerhub –

If I wanted to deploy this app in a Kubernetes cluster, a set of specs to create a Kubernetes Deployment and a service is available here – This is a simple enough deployment, however, the specs can get complicated once configuration, secrets are layered in and if features like Horizontal scaling is required.


There is a good documentation in the README of the chart, I will be mostly repeating that information here. I have hosted a version of the chart as a chart repository using github-pages, the first step to using the chart is to add this repo to your list of helm repos:

helm repo add bk-charts
helm repo update

The chart should now show up if searched for:

helm search generic-app-chart

The chart requires the details of the application that is being deployed, which can be provided as a yaml the following way:

  healthCheckPath: /actuator/info
    SERVER_PORT: "8080"
    enabled: true
    maxReplicas: 2
    minReplicas: 1
    targetCPUUtilizationPercentage: 40    

  repository: bijukunjummen/sample-boot-knative-app
  tag: 0.0.3-SNAPSHOT    

  enabled: true
  path: /
  annotations: nginx "cookie" "route"

    enabled: true
    cpu: 500m

At a minimum, the only details that are required are the application image and the tag, the rest of the details is just for illustration of what is feasible.

To deploy the app, run the following command:

helm install bk-charts/generic-app-chart  --name my-app --values sample-values.yaml

and a bunch of Kubernetes resources should show up supporting this application.

App upgrades are simple, facilitated by helm:

helm upgrade my-app bk-charts/generic-app-chart -f sample-values.yaml


The chart is fairly minimal at this point and creates a small set of Kubernetes resources – a secrets to hold secrets!, a deployment, a service, an hpa to scale the app, which suffices the kind of use cases that I have encountered so far.

Published on System Code Geeks with permission by Biju Kunjummen, partner at our SCG program. See the original article here: Helm chart to deploy and scale a generic app image

Opinions expressed by System Code Geeks contributors are their own.

Notify of

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Inline Feedbacks
View all comments
Back to top button