Navigating Helm: Simplify Kubernetes application configuration and deployment

If you use Kubernetes to deploy and manage applications in containerised environments, you’re no doubt already familiar with Helm, the indispensable Kubernetes package manager. But how far does your Helm knowledge currently stretch? Below, we’ll explore some advanced usage scenarios for Helm, specifically tailored for Tyk, so that you can easily manage different environments to get the best out of both Kubernetes and Tyk.

Managing different environments with Helm

One of Helm’s key features is its support for parameterization through values files and templating. This allows users to customise application configurations during deployment, making it a powerful tool for managing different environments – such as development, staging and production – with the same Helm chart.

Managing different environments in this way means you can efficiently and seamlessly deploy Tyk across various environments while maintaining consistency and flexibility. All by adjusting values files. Nice.

Example:

 

```bash

helm install tyk tyk-helm-chart/tyk-stack --values ./values-dev.yaml

```

 

GitOps deployment with ArgoCD or Flux

Would you prefer to move away from imperative deployment approaches? No problem. All you need to do is integrate Helm with declarative GitOps tools like ArgoCD or Flux. These tools allow you to define the desired state of your applications in Git repositories, automatically synchronising with your Kubernetes clusters. Helm, being the de facto standard for Kubernetes applications, seamlessly integrates with these tools, providing a more efficient and scalable approach to application deployment. Handily, Helm provides this quick summary of the tools you can use for declarative configuration management, including details of Helmfile, Captain, Terraform Helm provider, Orkestra and Fleet, as well as ArgoCD and Flux. With a range of options available, you can flex your tooling approach to suit your specific needs. To make things even easier, Tyk will play nicely with whichever tools you choose.

Templating API resources for security and governance

When you leverage Helm to template API resources, you have the power to enhance security, governance and developer experience all at once. Happy days. This is where Tyk Operator comes in. You can use Tyk Operator custom resources to enable the creation of API resources templates. Doing so means you can instantiate different APIs through Helm, ensuring consistency and adherence to policies. Want to see what we mean? Then check out this example to see how Helm can be used for templating Tyk API resources:

 

```yaml

apiVersion: tyk.tyk.io/v1alpha1

kind: ApiDefinition

metadata:

  name: tyk-cicd-demo-{{ include "httpbin.fullname" . }}

spec:

  contextRef:

    name: {{ .Values.api.operatorContext.name }}

    namespace: {{ .Values.api.operatorContext.namespace }}

  name: tyk-cicd-demo-{{ include "httpbin.fullname" . }}

  use_keyless: true

  protocol: http

  active: true

  proxy:

    target_url: http://{{ include "httpbin.fullname" . }}.{{ .Release.Namespace }}.svc:{{ .Values.service.port }}

    listen_path: {{ .Values.api.listenPath }}

    strip_listen_path: true

```

 

Harnessing the power of the “chart of charts”

Are you ready to scale your application deployment architecture? Then it’s time to use Helm’s “chart of charts” feature. This advanced technique allows the creation of Helm charts that manage other Helm charts as dependencies.

This is a hugely powerful capability – and one that Tyk takes full advantage of. We offer packaged deployments to meet various needs:

• tyk-oss for simple API gateway and telemetry requirements
• tyk-stack for a comprehensive API management platform
• tyk-control-plane for orchestrating remote data planes in a distributed architecture
• tyk-data-plane for setting up lightweight remote data planes

These are the “parent charts” or “umbrella charts” which configure required subcharts of the Tyk components (Tyk Gateway, Tyk Pump, Tyk Dashboard, MDCB and so on) as dependencies. This modular approach simplifies the deployment, maintenance and scaling of Tyk components. It means there’s a tailored solution for every use case, so you can achieve what you need to efficiently and painlessly.

Try it out: Tyk Charts – overview

Streamline your Tyk deployment workflow with Helm

Tyk continues to evolve as a leading API management platform, while Helm proves to be an invaluable ally for managing complex deployments. From handling different environments to templating API resources and orchestrating modular deployments, Helm unlocks new possibilities for Tyk users.

You can embrace the advanced Helm techniques above to streamline your Tyk deployment workflow and take full control of your Kubernetes environment. Head over to GitHub to access all of our latest Helm charts or chat with the Tyk team about your Helm-related plans.