Contents
1. What is Kubernetes
kubernetes (commonly stylized as k8s) is an open-source system for automating deployment, scaling, and management of containerized applications.
In this post, I will give you how to install minikube on Ubuntu 18.04, first let’s start with an introduction before diving to the installation steps.
Minikube is a tool that makes it easy to run Kubernetes locally. Minikube runs a single-node Kubernetes cluster inside a Virtual Machine (VM) on your laptop for users looking to try out Kubernetes or develop with it day-to-day.
2. Adience
This article is prepared for anyone who want to create cluster using kubernetes.
3. Prerequisites
- An SSH key pair on your local Linux/Mac OS/BSD machine.
- Three servers running Ubuntu 18.04 with at least 2GB RAM and 2 vCPUs each.
4. Kubernetes features supported by Minikube:
- DNS
- NodePorts
- ConfigMaps and Secrets
- Dashboards
As of this writing, Minikube does not yet support Cloud Provider specific features such as:
- LoadBalancers
- PersistentVolumes
- Ingress
Hypervisor choice for Minikube:
Minikube supports both VirtualBox and KVM hypervisors.
5. Minikube Installation
Step 1: Update system
firstly you can run the following commands to update all system packages to the latest release:
1 |
sudo apt-get update |

1 |
sudo apt-get install apt-transport-https |

1 |
sudo apt-get upgrade |

Step 2: Install KVM or VirtualBox Hypervisor
In this tutorial i will use Virtualbox as hypervisor, so you can use the following command in your terminal to install it :
1 |
sudo apt install virtualbox virtualbox-ext-pack |

Step 3: Download minikube
You need to download the minikube binary using the commands bellow
1 |
wget https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd6 |
1 |
chmod +x minikube-linux-amd64 |
1 |
sudo mv minikube-linux-amd64 /usr/local/bin/minikube |
Now we can check minikube version with this command
1 |
minikube version |

If Curl is not installed on your system, you can install it through the following command as root:
1 |
sudo apt install curl |
Step 4: Install kubectl on Ubuntu 18.04
We need kubectl which is a command line tool used to deploy and manage applications on Kubernetes cluster
1 |
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add - |

Add Kubernetes apt repository:
1 |
echo "deb http://apt.kubernetes.io/ kubernetes-xenial main" | sudo tee /etc/apt/sources.list.d/kubernetes.list |
Update apt index and install kubectl
1 |
sudo apt update |
1 |
sudo apt -y install kubectl |
Check if Kubectl is installed with the command below:
1 |
kubectl version |

Step 5: Starting minikube
Now that components are installed, we can start minikube. VM image in virtualbox will be downloaded and configured for Kubernetes single node cluster.null
1 |
minikube start |
Step 6: Minikube Basic operations
To check cluster status, run:
1 |
kubectl cluster-info |
To View Config, use:
1 |
kubectl config view |
To check running nodes:
1 |
kubectl get nodes |
To Access minikube VM using ssh:
1 |
minikube ssh |
1 |
sudo su - |
To stop a running local kubernetes cluster, run:
1 |
minikube stop |
To delete a local kubernetes cluster, use:
1 |
minikube delete |
6. Access Kubernetes Dashboard
By default, Kubernetes comes with web dashboard that can be used to manage our cluster, we can list all the minikube addons with the following command:
1 |
minikube addons list |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
- addon-manager: enabled - coredns: disabled - dashboard: enabled - default-storageclass: enabled - efk: disabled - freshpod: disabled - heapster: disabled - ingress: disabled - kube-dns: enabled - metrics-server: disabled - registry: disabled - registry-creds: disabled - storage-provisioner: enabled |
To open directly on our default browser :
1 |
minikube dashboard |
To get the URL of the dashboard
1 |
minikube dashboard --url |
1 |
http://192.168.39.117:30000 |
7. Conclusion
In this post, i have explained the installation of the Kubernetes cluster on Ubuntu using minikube.
If you have any questions or feedback, feel free to leave a comment.
As always, if you found this post useful, then click like and share it 🙂