
helm init: Install Tiller to your running Kubernetes cluster.
helm search: Search for charts
helm fetch: Download a chart to your local directory to view
helm install: Upload the chart to Kubernetes
helm list: List releases of charts
PRE-REQUISITES:
- You already have a Google Account and have access to Google Cloud Console (https://console.cloud.google.com)
- Billing account enabled that can be use in this project
Step 1: Create a Google Cloud Project OR select and existing Project
Step 2: Create a Kubernetes Cluster (select Kubernetes Engine menu item from the left side navigation -> Create Cluster -> Choose default settings)
Remember to delete the cluster after use. There is a free 300$ credit provided by Google Cloud for new users.
COMMANDS TO RUN DURING SETUP
helm init
kubectl create serviceaccount --namespace kube-system tiller
kubectl create clusterrolebinding tiller-cluster-rule --clusterrole=cluster-admin --serviceaccount=kube-system:tiller
kubectl patch deploy --namespace kube-system tiller-deploy -p '{"spec":{"template":{"spec":{"serviceAccount":"tiller"}}}}'
Demo 1: STABLE HELM CHART
helm search redis
helm fetch --untar stable/redis
tree helm inspect stable/redis (sudo apt update && sudo apt install tree -y, if you do not have tree package)
helm inspect stable/redis
helm inspect values stable/redis
helm upgrade --install — this is helpful especially when running the command in pipelines,
helm install/upgrade --debug — this allows you to see what happened in case of an install or upgrade.
helm install/upgrade --set name=sandbox — You have the possibility to overwrite values to an installation/upgrade by using the set flag.
Demo 3: CUSTOM CHARTS
• git clone https://github.com/CloudAndContainer/helmdemo.git
• Edit values.yaml and update the index values
• helm lint ./helmdemo
• helm install --name helmdemo ./helmdemo
• kubectl get svc
• kubectl get pods
• kubectl exec -it [YOUR_POD_NAME] sh
• curl [CLUSTER_IP]:80 (apt-get update && apt-get install curl -y, if curl is not installed)
Demo 3: CUSTOM CHARTS (cont’d..) – helm upgrade
• Edit values.yaml and update the index values
• helm upgrade helmDemo ./helmDemo
• helm rollback helmDemo 1
• helm package ./helmDemo
• kubectl get svc
• kubectl get pods
• kubectl exec -it [YOUR_POD_NAME] sh
• curl [CLUSTER_IP]:80 (apt-get update && apt-get install curl -y, if curl is not installed)
Welcome to Helm – The Kubernetes Package Manager Course. The course focuses on detailing the use of Helm to manage the Kubernetes deployments. You will learn on how to use the custom charts, reuse the available charts and much more. There are 2 main sections on how to use the stable charts and on how to make custom charts.
The ideal student for this course would be DevOps engineers or software developers or sysadmins or anyone who are dealing with Kubernetes projects or have an understanding about Kubernetes and would like to apply the deployment best practices using Helm and to understand more about Helm.
Pre-requisites:
- You already have a Google Account and have access to Google Cloud Console
- Billing account enabled that can be use in this project
Step 1: Create a Google Cloud Project OR select and existing Project
Step 2: Create a Kubernetes Cluster (select Kubernetes Engine menu item from the left side navigation -> Create Cluster -> Choose default settings)
Remember to delete the cluster after use. There is a free 300$ credit provided by Google Cloud for new users.