Minikube is an Open Source all-in-one Kubernetes cluster which runs on your Linux system. It is under the CNCF umbrella. The cluster operates inside a virtual machine and includes the container runtime environment that containers could run inside the node.
This is the easiest way to provision a Kubernetes cluster for testing and developing on your local environment.
In this context, we shall look into steps to install Minikube on your Ubuntu 20.04 machine.
To begin with this Installation procedure, make sure that you perform the following steps.
Always ensure that the system is up to date. So update the software packages list by running the following commands:
$ sudo apt update
$ sudo apt upgrade
Also install the below packages:
$ sudo apt install curl
$ sudo apt install apt-transport-https
In order to set up a single-node Kubernetes cluster with Minikube, you have to create a virtual machine on your Ubuntu machine. You can choose VirtualBox or KVM. In this guide, we use VirtualBox:
$ sudo apt install virtualbox virtualbox-ext-pack
Now, it's time to download the latest Minikube from the official repository:
$ wget https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
This command will install minikube to the system and you have to grant the execute permission to it:
$ chmod +x minikube-linux-amd64
Next, move the minikube file to /usr/local/bin directory:
$ sudo mv minikube-linux-amd64 /usr/local/bin/minikube
To check the minikube version installed, execute the command:
$ minikube version
In order to provision the All-In-One Kubernetes cluster, let’s start the minikube by running the following command:
$ minikube start
To interact with the Kubernetes cluster, you have to install the kubectl tool with the below command:
$ curl -LO https://storage.googleapis.com/kubernetes-release/release/`curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt`/bin/linux/amd64/kubectl
To grant permission, execute the command:
$ chmod +x kubectl
Then, move the kubectl binary to /usr/local/bin:
$ sudo mv kubectl /usr/local/bin
Now, you can run some basic commands with kubectl to interact with your Kubernetes cluster.
To show the running node:
$ kubectl get node
To get the cluster information:
$ kubectl cluster-info
This article covers how to install Minikube on your Ubuntu 20.04 machine. Minikube is an open source tool that allows you to set up a single-node Kubernetes cluster on your local machine. The cluster is run inside a virtual machine and includes Docker, allowing you to run containers inside the node.
Now, you can use the single-node Kubernetes with minikube to learn one of the most famous containers orchestration tools in the Cloud Native era.
To enable and access kubernetes dashboard , run the command:
$ minikube dashboard
This will open the Kubernetes dashboard in the web browser.
To stop the minikube, run:
$ minikube stop
To delete the minikube, run:
$ minikube delete
To Start the minikube, run:
$ minikube start