- January 22, 2018
- Posted by: Harmeek Jhutty
- Category: Azure, Helm, Jenkins, Kubernetes
In our last blog, we showed how to deploy a Kubernetes cluster in Azure Container Service (AKS). In this blog, we will cover how to deploy Jenkins with Helm in a Kubernetes cluster. Helm charts helps you define, install, and upgrade complex Kubernetes applications. Jenkins Helm chart installs a master and slave cluster utilizing the Jenkins Kubernetes plugin.
Jenkins is a very popular open source automation server written in Java. Jenkins helps to automate the non-human part of software development process, with continuous integration and facilitating technical aspects of continuous delivery and plays a key role in setting up an automated CI CD pipeline with Kubernetes.
Helm is an open-source packaging tool that helps you install and manage the lifecycle of Kubernetes applications.
Helm has two components:
- The Helm CLI is a client that runs on your machine locally or in the cloud
- Tiller is a server that runs on the Kubernetes cluster and manages the lifecycle of your Kubernetes applications
Create a Kubernetes cluster in Azure Container Service (AKS)
Install Helm on a local computer
After you have installed Helm, install Tiller on your Kubernetes cluster by typing the following command:
Deploying Jenkins with Helm chart
To deploy Jenkins with Helm using default configuration, type the following command:
To deploy Jenkins with Helm using custom configuration, clone the Jenkins Helm repository and then update stable/jenkins/values.yaml file:
Here’s our sample values.yaml file:
After the values.yaml file is updated, you can run the following command:
After updating values.yaml, you can deploy it using this command:
1. Get your ‘coderiseio’ user password by running:
2. Get the Jenkins URL to visit by running these commands in the same shell:
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
You can watch the status of by running:
3. Login with the password from step 1 and the username specified in values.yaml: admin(default). In our case, we set it to coderiseio.
In this blog, we showed you how to deploy Jenkins with Helm on Kubernetes cluster in Azure Container Service (AKS). The same commands should work fine on AWS, GCP and IBM Cloud as well. If you have any questions or have a better approach, please use comments section below to share with us!