Skip to content

Contact sales

By filling out this form and clicking submit, you acknowledge our privacy policy.
  • Labs icon Lab
  • A Cloud Guru
Google Cloud Platform icon
Labs

Installing and Testing Helm and Tiller

This Hands-On Lab is intended to provide practice with installing and configuring Helm in a Kubernetes environment.

Google Cloud Platform icon
Labs

Path Info

Level
Clock icon Intermediate
Duration
Clock icon 1h 0m
Published
Clock icon Apr 05, 2019

Contact sales

By filling out this form and clicking submit, you acknowledge our privacy policy.

Table of Contents

  1. Challenge

    Install Helm and Tiller in the Existing Cluster

    Download the helm binary release:

    [user@host]$ curl https://get.helm.sh/helm-v2.17.0-linux-amd64.tar.gz > ./helm.tar.gz
    

    Extract the archive:

    [user@host]$ tar -xvf ./helm.tar.gz
    

    Navigate to the linux-amd64 directory:

    [user@host]$ cd linux-amd64
    

    Move the helm and tiller executable files to the /usr/local/bin directory:

    [user@host]$ sudo mv ./helm /usr/local/bin
    [user@host]$ sudo mv ./tiller /usr/local/bin
    

    Run the helm version command to ensure that the helm command is available:

    [user@host]$ helm version
    

    Install tiller:

    [user@host]$ helm init --stable-repo-url https://charts.helm.sh/stable 
    

    Run the version command again to ensure that Tiller is available:

    [user@host]$ helm version
    
  2. Challenge

    Deploy, Troubleshoot, and Verify Deployment of the NGINX Chart

    Ensure that you are in the cloud_user home directory. This directory contains the nginx chart at /home/cloud_user/nginx:

    [cloud_user@host]$ cd ~
    

    This command should return a directory listing containing Chart.yaml:

    [cloud_user@host]$ls ./nginx
    

    Install the nginx chart:

    [cloud_user@host]$ helm install ./nginx
    

    This command should error with a "name" error, due to the tiller service account missing.
    Add the tiller service account:

    [cloud_user@host]$ kubectl create serviceaccount --namespace kube-system tiller
    [cloud_user@host]$ kubectl create clusterrolebinding tiller-cluster-rule --clusterrole=cluster-admin --serviceaccount=kube-system:tiller
    [cloud_user]$ kubectl patch deploy --namespace kube-system tiller-deploy -p'{"spec":{"template":{"spec":{"serviceAccount":"tiller"}}}}'
    

    Wait for the tiller pod to restart with the update, and then install the nginx example chart:

    [cloud_user@host]$ helm install ./nginx
    

    Once the release has completed and you see the release output, locate the cluster IP for the service that has been created. Then confirm that the nginx pod has been deployed correctly.

    [cloud_user@host]$ curl "service cluster ip":8888
    

    This should return an html message.

    Clean up the test deployment, get the release name from Helm, and then delete the release:

    [cloud_user@host]$ helm ls --short
    [cloud_user@host]$ helm delete "return from previous command"
    

    Confirm that the release has been removed. The following commands should return nothing:

    [cloud_user@host]$ helm ls  
    [cloud_user@host]$ kubectl get pods
    

The Cloud Content team comprises subject matter experts hyper focused on services offered by the leading cloud vendors (AWS, GCP, and Azure), as well as cloud-related technologies such as Linux and DevOps. The team is thrilled to share their knowledge to help you build modern tech solutions from the ground up, secure and optimize your environments, and so much more!

What's a lab?

Hands-on Labs are real environments created by industry experts to help you learn. These environments help you gain knowledge and experience, practice without compromising your system, test without risk, destroy without fear, and let you learn from your mistakes. Hands-on Labs: practice your skills before delivering in the real world.

Provided environment for hands-on practice

We will provide the credentials and environment necessary for you to practice right within your browser.

Guided walkthrough

Follow along with the author’s guided walkthrough and build something new in your provided environment!

Did you know?

On average, you retain 75% more of your learning if you get time for practice.

Start learning by doing today

View Plans