Reader small image

You're reading from  Learn Helm

Product typeBook
Published inJun 2020
PublisherPackt
ISBN-139781839214295
Edition1st Edition
Right arrow
Authors (2):
Andrew Block
Andrew Block
author image
Andrew Block

Andrew Block is a core maintainer on the Helm project and a Distinguished Architect at Red Hat. He specializes in the use of continuous integration and continuous delivery methodologies to streamline the delivery process and incorporate security at each stage. He works with organizations to adopt and implement these technologies and concepts within their organization. As an open source enthusiast, Andrew not only has authored several publications, but he is also a contributor to several open source communities and a lead within the sigstore project, which aims at simplifying how software is signed and verified.
Read more about Andrew Block

Austin Dewey
Austin Dewey
author image
Austin Dewey

Austin Dewey is a DevOps engineer focused on delivering a streamlined developer experience on cloud and container technologies. Austin started his career with Red Hat's consulting organization, where he helped drive success at Fortune 500 companies by automating deployments on Red Hat's Kubernetes-based PaaS, OpenShift Container Platform. Currently, Austin works at fintech start-up Prime Trust, where he builds automation to scale financial infrastructure and supports developers on Kubernetes and AWS.
Read more about Austin Dewey

View More author details
Right arrow

Questions

  1. What is the difference between a monolithic and a microservices application?
  2. What is Kubernetes? What problems was it designed to solve?
  3. What are some of the kubectl commands commonly used when deploying applications to Kubernetes?
  4. What challenges are often involved in deploying applications to Kubernetes?
  5. How does Helm function as a package manager for Kubernetes? How does it address the challenges posed by Kubernetes?
  6. Imagine you want to roll back an application deployed on Kubernetes. What Helm command allows you to perform this action? How does Helm keep track of your changes to make this rollback possible?
  7. What are the four primary Helm commands that allow Helm to function as a package manager?

Technical requirements

In this chapter, you will install the following technologies to your local workstation:

  • Minikube
  • VirtualBox
  • Helm

These tools can be installed with a package manager or by downloading them directly from a download link. We will provide instructions for using the Chocolatey package manager on Windows, the Homebrew package manager on macOS, the apt-get package manager for Debian-based Linux distributions, and the dnf package manager for RPM-based Linux distributions.

Preparing a local Kubernetes environment with Minikube

Helm won't be able to deploy applications without access to a Kubernetes cluster. For this reason, let's discuss one option that users can follow to run their own cluster on their machine—Minikube.

Minikube is a community-driven tool that allows users to easily deploy a small, single-node Kubernetes cluster to their local machine. A cluster created with Minikube is created inside a virtual machine (VM), so it can be created and later discarded in a way that is isolated from the host operating system that the VM is running on. Minikube presents an excellent way to experiment with Kubernetes and it can also be used to learn how to use Helm alongside the examples provided throughout this book.

In the next few sections, we'll cover how Minikube can be installed and configured so that you have a Kubernetes cluster available while learning how to use Helm. For more comprehensive instructions, please refer...

Setting up Kubectl

As mentioned in Chapter 1, Understanding Kubernetes and Helm, Kubernetes is a system that exposes different API endpoints. These API endpoints are used to perform various actions on a cluster, such as creating, viewing, or deleting resources. To provide simpler user experience, developers need a way of interacting with Kubernetes without having to manage the underlying API layer.

While you will predominantly use the Helm command-line tool throughout the course of this book to install and manage applications, kubectl is an essential tool for common tasks.

Read on to learn how to install kubectl on a local workstation. Note that the kubectl version used at the time of writing is v1.16.2.

Installing Kubectl

Kubectl can be installed using Minikube or it can be obtained via a package manager or through direct download. We will first describe how to obtain kubectl using Minikube.

Installing Kubectl via Minikube

The installation of kubectl is straightforward...

Configuring Helm

Helm is a tool with sensible defaults that allow users to be productive without needing to perform a large number of tasks post-installation. With that being said, there are several different options users can change or enable to modify Helm's behavior. We will cover these options in the following sections, beginning with the configuration of upstream repositories.

Adding upstream repositories

One way that users can begin to modify their Helm installation is by adding upstream chart repositories. In Chapter 1, Understanding Kubernetes and Helm, we described how chart repositories contain Helm charts, which are used to package Kubernetes resource files. Helm, being the Kubernetes package manager, can connect to various chart repositories to install Kubernetes applications.

Helm provides the repo subcommand to allow users to manage configured chart repositories. This subcommand contains additional subcommands that can be used to perform actions against...

Summary

There are a variety of different components you will need to have available in order to start using Helm. In this chapter, you learned how to install Minikube to provide a local Kubernetes cluster that can be used throughout this book. You also learned how to install Kubectl, which is the official tool for interacting with the Kubernetes API. Finally, you learned how to install the Helm client and explored the various ways that Helm can be configured, which includes adding repositories and plugins, modifying environment variables, enabling tab completion, and configuring authentication and authorization against a Kubernetes cluster.

Now that you have the prerequisite tooling installed, you can begin to learn how to deploy your first application with Helm. In the next chapter, you will install a Helm chart from an upstream chart repository, as well as learn about life cycle management and application configuration. After finishing the chapter, you will have an understanding...

Further reading

Check out the following links to learn more about the installation options available for Minikube, Kubectl, and Helm:

We covered various different ways of configuring Helm post-installation. Check out the following links to learn more about the following topics:

Questions

  1. Can you list the various methods you can use to install the Helm client?
  2. How does Helm authenticate to a Kubernetes cluster?
  3. What mechanism is in place to provide authorization to the Helm client? How can an administrator manage these privileges?
  4. What is the purpose of the helm repo add command?
  5. What are the three XDG environment variables used by Helm? What purpose do they serve?
  6. Why is Minikube a good choice for learning how to use Kubernetes and Helm? What does Minikube automatically configure for users to allow them to get started more rapidly?
lock icon
The rest of the chapter is locked
You have been reading a chapter from
Learn Helm
Published in: Jun 2020Publisher: PacktISBN-13: 9781839214295
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €14.99/month. Cancel anytime

Authors (2)

author image
Andrew Block

Andrew Block is a core maintainer on the Helm project and a Distinguished Architect at Red Hat. He specializes in the use of continuous integration and continuous delivery methodologies to streamline the delivery process and incorporate security at each stage. He works with organizations to adopt and implement these technologies and concepts within their organization. As an open source enthusiast, Andrew not only has authored several publications, but he is also a contributor to several open source communities and a lead within the sigstore project, which aims at simplifying how software is signed and verified.
Read more about Andrew Block

author image
Austin Dewey

Austin Dewey is a DevOps engineer focused on delivering a streamlined developer experience on cloud and container technologies. Austin started his career with Red Hat's consulting organization, where he helped drive success at Fortune 500 companies by automating deployments on Red Hat's Kubernetes-based PaaS, OpenShift Container Platform. Currently, Austin works at fintech start-up Prime Trust, where he builds automation to scale financial infrastructure and supports developers on Kubernetes and AWS.
Read more about Austin Dewey