Back to Tech Corner
DevOps

(Jan 2024) DevOps – How to Install minikube

In the previous article we installed kubectl (read here: https://bit.ly/47MLmlN), a command line utility to interact with Kubernetes cluster. In this article we will go through installing minikube. minikube allows you to run kubernetes cluster locally just like kind; which requires Docker or Podman.

Steps to Install minikube on a Linux RHEL release 8.8 (Ootpa)

Requirements

  • 2 CPUs or more
  • 2GB of free memory
  • 20GB of free disk space
  • Internet connection
  • Container or virtual machine manager, such as: Docker, QEMU, Hyperkit, Hyper-V, KVM, Parallels, Podman, VirtualBox, or VMware Fusion/Workstation

For this particular installation we are using Podman. The docker package is not shipped or supported by Red Hat for Red Hat Enterprise Linux (RHEL) 8 and (RHEL) 9. The docker container engine is replaced by a suite of tools in the Container Tools module.

The podman container engine replaced docker as the preferred, maintained, and supported container runtime of choice for Red Hat Enterprise Linux 8 and 9 systems. The podman provides a docker compatible command line experience enabling users to find, run, build, and share containers. The podman uses buildah and skopeo as libraries for the build and push.

Read more about these tools here: https://red.ht/3SbNQ7b

Install Podman Steps

  1. As sudo or root it is a good habit to run updates

    sudo dnf -y update
  2. Confirm Podman is not already installed

    which podman
  3. Install podman

    sudo yum module enable -y container-tools:rhel8
    sudo yum module install -y container-tools:rhel8

    The container-tools:rhel8 is the fast application stream, containing most recent rolling versions of the tools. Use the container-tools:2.0 stream for stable versions of Podman 1.6. The command yum module list container-tools shows the available streams.

  4. Confirm podman installed

    which podman

Install minikube

To install the latest minikube stable release on x86-64 Linux using binary download:

curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
sudo install minikube-linux-amd64 /usr/local/bin/minikube

The install command does not produce any output, to confirm that minikube was installed run which minikube.

Start Cluster

minikube start

Note: Fix: Add sas ID to the Sudoers file for podman command

Interact with New Cluster

Kubectl was installed with minikube following are some examples of interacting with new cluster:

minikube kubectl -- get po

You can also create an alias:

alias kubectl="minikube kubectl --"

For additional insight into your cluster state, minikube bundles the Kubernetes Dashboard, allowing you to get easily acclimated to your new environment:

minikube dashboard

Appendix

To install Docker on Linux supported platforms such as Fedora, Ubuntu, Debian there is a script available to facilitate easy installation experience. Read through the comments and this installation is not recommended for Production environments. Script is get.docker.com.