Deploying NGINX on Kubernetes using the Bitnami Helm Chart simplifies the deployment of the popular web server on a Kubernetes cluster. The Bitnami NGINX Helm Chart includes a single replica deployment of NGINX and a service to expose it to other Kubernetes resources. By using the Bitnami Helm Chart, you don't need to worry about configuring NGINX from scratch, and you can take advantage of the additional features and security patches provided by Bitnami. After installing the Helm chart, you can create Kubernetes ingress resources to route traffic to your services and take advantage of NGINX's capabilities as a reverse proxy and load balancer. Overall, using the Bitnami Helm Chart can help you deploy NGINX on Kubernetes more quickly and with less configuration. In this tutorial, I'll show you how to deploy the NGINX helm chart on Kubernetes using a CD tool.
Prerequisites
Free Harness cloud account (on-premise)
A Kubernetes cluster access to deploy our Helm chart. You can use Minikube or Kind for a cluster access.
Docker installed. Testing on Docker Desktop.
Tutorial
To deploy the Bitnami NGINX Helm chart, you need a continuous delivery platform, and we are making use of a best-in-class tool, Harness.
Signup to Harness and login to your account.
![harness - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_f33ea1d7660a4c389e50496b635da2c0~mv2.png/v1/fill/w_880,h_600,al_c,q_90,enc_avif,quality_auto/273a18_f33ea1d7660a4c389e50496b635da2c0~mv2.png)
Next, create a project
![harness create project - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_7729492e870e49a9b6bf380fc5f5eea5~mv2.png/v1/fill/w_880,h_799,al_c,q_90,enc_avif,quality_auto/273a18_7729492e870e49a9b6bf380fc5f5eea5~mv2.png)
Add details for the project, name it as per your wish.
![harness project detail - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_e4a76d7b59a14dd2bc6cdce086369394~mv2.png/v1/fill/w_880,h_679,al_c,q_90,enc_avif,quality_auto/273a18_e4a76d7b59a14dd2bc6cdce086369394~mv2.png)
Invite collaborators if you want to your CD project.
![harness invite collaborators - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_0cec2be444ee4f77a249aa59edabc827~mv2.png/v1/fill/w_880,h_550,al_c,q_90,enc_avif,quality_auto/273a18_0cec2be444ee4f77a249aa59edabc827~mv2.png)
Select the Continuous Delivery module for the project.
![harness continuous delivery - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_511e5a6effde44a99c7338968a11cc56~mv2.png/v1/fill/w_880,h_471,al_c,q_90,enc_avif,quality_auto/273a18_511e5a6effde44a99c7338968a11cc56~mv2.png)
Start your CD journey from here
![harness start deployments - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_d0a9bc21a99d4d27a803185570311ca0~mv2.png/v1/fill/w_880,h_430,al_c,q_90,enc_avif,quality_auto/273a18_d0a9bc21a99d4d27a803185570311ca0~mv2.png)
Select your deployment type and click on other deployment types. [We are focused on Helm deployment]
![harness select deployment type - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_70dbfda786ba4cf7841f4cc796346a7c~mv2.png/v1/fill/w_880,h_990,al_c,q_90,enc_avif,quality_auto/273a18_70dbfda786ba4cf7841f4cc796346a7c~mv2.png)
Start creating a pipeline for your project.
![harness start creating pipelines - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_b5d60999877f4217979718c5142361f8~mv2.png/v1/fill/w_880,h_882,al_c,q_90,enc_avif,quality_auto/273a18_b5d60999877f4217979718c5142361f8~mv2.png)
Add details of the pipeline
![harness add detail to pipelines - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_1d81b392a75448d8bef31b2e1611734d~mv2.png/v1/fill/w_880,h_615,al_c,q_90,enc_avif,quality_auto/273a18_1d81b392a75448d8bef31b2e1611734d~mv2.png)
Select 'Deploy' as stage
![harness select deployment stage - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_b180a408d49541ecb6dc91d653e3ba36~mv2.png/v1/fill/w_880,h_481,al_c,q_90,enc_avif,quality_auto/273a18_b180a408d49541ecb6dc91d653e3ba36~mv2.png)
Select the deployment type as Native Helm
![harness select deployment type - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_1e2ca412157446a498320e48f78c952a~mv2.png/v1/fill/w_880,h_528,al_c,q_90,enc_avif,quality_auto/273a18_1e2ca412157446a498320e48f78c952a~mv2.png)
Create a service for the project
![harness create service for project - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_96473f9edc064f7ebc29f6ea5fc645d4~mv2.png/v1/fill/w_880,h_505,al_c,q_90,enc_avif,quality_auto/273a18_96473f9edc064f7ebc29f6ea5fc645d4~mv2.png)
Add Service
![harness add new service to project - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_d99699a4276e4e39a20bb5dc129bb1f6~mv2.png/v1/fill/w_880,h_1217,al_c,q_90,enc_avif,quality_auto/273a18_d99699a4276e4e39a20bb5dc129bb1f6~mv2.png)
Add manifest details, select Helm Chart
![harness specify manifest type - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_a7f529ae0ad140bfbebd4e1681f4ae04~mv2.png/v1/fill/w_880,h_837,al_c,q_90,enc_avif,quality_auto/273a18_a7f529ae0ad140bfbebd4e1681f4ae04~mv2.png)
Select HTTP Helm
![harness select http helm - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_37ddf7af1eb44a6ab1c356b9e4ddcc11~mv2.png/v1/fill/w_880,h_491,al_c,q_90,enc_avif,quality_auto/273a18_37ddf7af1eb44a6ab1c356b9e4ddcc11~mv2.png)
Specify the Helm chart store
![harness specify helm chart store - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_2d3169cfd0e54bb0a752cee32f8a5e7c~mv2.png/v1/fill/w_880,h_500,al_c,q_90,enc_avif,quality_auto/273a18_2d3169cfd0e54bb0a752cee32f8a5e7c~mv2.png)
Create a new HTTP Helm Repo Connector
![harness connector overview - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_b2a3b312f26e44ab9c355fe5ba18aed3~mv2.png/v1/fill/w_880,h_725,al_c,q_90,enc_avif,quality_auto/273a18_b2a3b312f26e44ab9c355fe5ba18aed3~mv2.png)
Add the Helm repo connector details
![harness helm chart store credentials - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_7640eaecd35841ca832f10f049ba4221~mv2.png/v1/fill/w_880,h_655,al_c,q_90,enc_avif,quality_auto/273a18_7640eaecd35841ca832f10f049ba4221~mv2.png)
Connect the Helm repo with the Harness Delegate.
![harness delegates setup - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_960601a65fa64a208c8585971cafc95d~mv2.png/v1/fill/w_880,h_509,al_c,q_90,enc_avif,quality_auto/273a18_960601a65fa64a208c8585971cafc95d~mv2.png)
So, what is Harness Delegate?
A Delegate is a service that runs on your infrastructure to execute tasks on behalf of the Harness platform.
Now, you need to install this Harness Delegate on your Kubernetes cluster.
Make sure you have a cluster access from any cloud provider.
Nothing to worry about if you don't have access to any cluster access. We will make use of Minikube.
Install Minikube on your local machine by following this link.
Once the installation is complete, start the Minikube cluster with the following command.
$ minikube start
You should see a successful output as shown below:
![harness minikube start - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_297a470f1f324f7e95448cb38dec755c~mv2.png/v1/fill/w_880,h_454,al_c,q_90,enc_avif,quality_auto/273a18_297a470f1f324f7e95448cb38dec755c~mv2.png)
It is time to install our Harness Delegate
![harness new delegates - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_52b739d9f6f24de39bf0c3a4cb7d74e7~mv2.png/v1/fill/w_880,h_671,al_c,q_90,enc_avif,quality_auto/273a18_52b739d9f6f24de39bf0c3a4cb7d74e7~mv2.png)
Run the commands as shown in the installation process
![harness helm repo update upgrade - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_db8bc153ca8b446fa7b3198447ea8ea1~mv2.png/v1/fill/w_880,h_685,al_c,q_90,enc_avif,quality_auto/273a18_db8bc153ca8b446fa7b3198447ea8ea1~mv2.png)
Once done, verify if the Delegate has been installed successfully.
![harness install your delegate - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_9cd63df62f934c7e88cc210c65bc44cb~mv2.png/v1/fill/w_880,h_964,al_c,q_90,enc_avif,quality_auto/273a18_9cd63df62f934c7e88cc210c65bc44cb~mv2.png)
Let's go back to the steps where we stopped previously (before installing the Harness Delegate).
Now you should see the Delegate we just installed. Select the same and continue.
![harness delegates setup - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_d67820a0ea014130aefd63bdc4df7812~mv2.png/v1/fill/w_880,h_513,al_c,q_90,enc_avif,quality_auto/273a18_d67820a0ea014130aefd63bdc4df7812~mv2.png)
You should see a successful connection between the helm repo and our Delegate.
![harness connection test - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_259739700e114a9cb60dec216f606ed7~mv2.png/v1/fill/w_880,h_467,al_c,q_90,enc_avif,quality_auto/273a18_259739700e114a9cb60dec216f606ed7~mv2.png)
Next, add the manifest details as shown
![harness manifest details - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_70dd9d53333a43479633a81200c2b5e0~mv2.png/v1/fill/w_880,h_435,al_c,q_90,enc_avif,quality_auto/273a18_70dd9d53333a43479633a81200c2b5e0~mv2.png)
You should see the manifest details we added
![harness new service in projects - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_5b605d8f54ff44c6875b8e3726cf63ff~mv2.png/v1/fill/w_880,h_800,al_c,q_90,enc_avif,quality_auto/273a18_5b605d8f54ff44c6875b8e3726cf63ff~mv2.png)
You should see the service added; click Continue.
![harness nginx helm deployment - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_3a14d06d15b64eebbdd9d061d0be524e~mv2.png/v1/fill/w_880,h_699,al_c,q_90,enc_avif,quality_auto/273a18_3a14d06d15b64eebbdd9d061d0be524e~mv2.png)
Add new environment as pre-prod
![harness specify environment - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_fe8b3cae747d48ffabd4f78a5a50a7eb~mv2.png/v1/fill/w_880,h_309,al_c,q_85,enc_avif,quality_auto/273a18_fe8b3cae747d48ffabd4f78a5a50a7eb~mv2.png)
Click New Environment.
![harness create new environment - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_29cef7df52f34854a0dc9d58a9a7762e~mv2.png/v1/fill/w_880,h_1514,al_c,q_90,enc_avif,quality_auto/273a18_29cef7df52f34854a0dc9d58a9a7762e~mv2.png)
Similarly, add a new infrastructure
![harness select environment - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_b3a01881d3434066a60abafdd4a55a90~mv2.png/v1/fill/w_880,h_527,al_c,q_90,enc_avif,quality_auto/273a18_b3a01881d3434066a60abafdd4a55a90~mv2.png)
Select 'Kubernetes' here.
![harness select infrastructure type - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_30584e4c76e4445cb2685f771bfc5c46~mv2.png/v1/fill/w_880,h_1295,al_c,q_90,enc_avif,quality_auto/273a18_30584e4c76e4445cb2685f771bfc5c46~mv2.png)
Under cluster details, select the connector and add the cluster details.
![harness kubernetes k8s cluster connection overview - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_0d250e5d266c4328a24fdc532a902825~mv2.png/v1/fill/w_880,h_716,al_c,q_90,enc_avif,quality_auto/273a18_0d250e5d266c4328a24fdc532a902825~mv2.png)
Let's connect our infrastructure with our Delegate.
![harness kubernetes cluster connection details - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_adfb6c2981ed4533a29087c87ff51c4a~mv2.png/v1/fill/w_880,h_506,al_c,q_90,enc_avif,quality_auto/273a18_adfb6c2981ed4533a29087c87ff51c4a~mv2.png)
Click Continue.
![harness kubernetes cluster connection delegates setup - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_8e1efcfd806f4924aea0db3a1c585e1b~mv2.png/v1/fill/w_880,h_560,al_c,q_90,enc_avif,quality_auto/273a18_8e1efcfd806f4924aea0db3a1c585e1b~mv2.png)
Make sure the connection is successful
![harness kubernetes cluster connection test - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_9b75c6eca1aa488db3e4d575b0f5900e~mv2.png/v1/fill/w_880,h_527,al_c,q_90,enc_avif,quality_auto/273a18_9b75c6eca1aa488db3e4d575b0f5900e~mv2.png)
You should see the cluster details and connector in the infrastructure
![harness kubernetes namespace connector - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_1f017ddd9cc14b06b666cc1a52600ba2~mv2.png/v1/fill/w_880,h_1193,al_c,q_90,enc_avif,quality_auto/273a18_1f017ddd9cc14b06b666cc1a52600ba2~mv2.png)
You should see the infrastructure we just added.
![harness specify infrastructure - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_487de451bde04bb2b96f3063e5ac5673~mv2.png/v1/fill/w_880,h_651,al_c,q_90,enc_avif,quality_auto/273a18_487de451bde04bb2b96f3063e5ac5673~mv2.png)
Click Continue and you will go to the execution step where we should select the deployment type. We will select 'Rolling'.
![harness execution strategy - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_39d8d0f1d6a84268a13e6e762e0ddf67~mv2.png/v1/fill/w_816,h_606,al_c,q_90,enc_avif,quality_auto/273a18_39d8d0f1d6a84268a13e6e762e0ddf67~mv2.png)
Finally, this is how our Helm chart deployment looks like.
![harness execution - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_180d98d74b634968ab41d0189049bf91~mv2.png/v1/fill/w_880,h_585,al_c,q_90,enc_avif,quality_auto/273a18_180d98d74b634968ab41d0189049bf91~mv2.png)
Save the pipeline and run it.
![harness save pipelines and run it - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_86064dfe64bd4abab40a93deca9eadf0~mv2.png/v1/fill/w_880,h_729,al_c,q_90,enc_avif,quality_auto/273a18_86064dfe64bd4abab40a93deca9eadf0~mv2.png)
You should see a successful execution of all the steps.
![harness successful deployment - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_b9334c1a3ee2492e9ded080b0edb9227~mv2.png/v1/fill/w_880,h_539,al_c,q_90,enc_avif,quality_auto/273a18_b9334c1a3ee2492e9ded080b0edb9227~mv2.png)
Let's get to the console view for more clarity.
![harness console view - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_1454d6391e0543ccbffbfbb669fcddc8~mv2.png/v1/fill/w_880,h_755,al_c,q_90,enc_avif,quality_auto/273a18_1454d6391e0543ccbffbfbb669fcddc8~mv2.png)
Let's verify if the NGINX deployment is done properly using the command
$ kubectl get deployment
You should see the following output
![kube get deployment - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_e7be24f554cb4322844890756161cea9~mv2.png/v1/fill/w_880,h_70,al_c,q_85,enc_avif,quality_auto/273a18_e7be24f554cb4322844890756161cea9~mv2.png)
Let's expose the deployed NGINX to the outside world and see if we can access it.
![kube get service - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_1f3e3fed8bbd453bbaa0d88a376d36f5~mv2.png/v1/fill/w_880,h_74,al_c,q_85,enc_avif,quality_auto/273a18_1f3e3fed8bbd453bbaa0d88a376d36f5~mv2.png)
As you can see, the external IP is pending.
We can expose the external IP using the below minikube command:
$ minikube tunnel
You should see the following output:
![minikube tunnel - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_e26838ec778a46c2bd3af85315d04407~mv2.png/v1/fill/w_880,h_137,al_c,q_85,enc_avif,quality_auto/273a18_e26838ec778a46c2bd3af85315d04407~mv2.png)
Now, open a new terminal window and run the following command
$ kubectl get service
You should see the external IP now.
![kube get service - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_e940274bcd194dc582807bbab7356a2c~mv2.png/v1/fill/w_880,h_77,al_c,q_85,enc_avif,quality_auto/273a18_e940274bcd194dc582807bbab7356a2c~mv2.png)
We can access the NGINX using the externalip:port
![nginx welcome page - How to deploy Nginx on Kubernetes using Helm Chart](https://static.wixstatic.com/media/273a18_e37b00b2d7d1429e9cf2781d50d06f3d~mv2.png/v1/fill/w_880,h_468,al_c,q_90,enc_avif,quality_auto/273a18_e37b00b2d7d1429e9cf2781d50d06f3d~mv2.png)
Congratulations! We successfully deployed an NGINX helm chart on Kubernetes using Harness CD module.
This way, you can easily deploy any of the Helm charts listed here on Kubernetes using the Harness Continuous Delivery module.
Comments