Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Install Kubernetes on Ubuntu 18.04

Install Kubernetes on Ubuntu 18.04

Quick guide to install Kubernetes via Minikube on Ubuntu 18.04.

1. Install VirtualBox

Install VirtualBox to be used as the hypervisor.

sudo apt-get install -y virtualbox virtualbox-ext-pack

2. Install kubectl

Install kubectl, the kubernetes command line tool.

sudo apt-get update && \
  sudo apt-get install -y apt-transport-https && \
  curl -s | sudo apt-key add - && \
  sudo touch /etc/apt/sources.list.d/kubernetes.list && \
  echo "deb kubernetes-xenial main" | sudo tee -a /etc/apt/sources.list.d/kubernetes.list && \
  sudo apt-get update && \
  sudo apt-get install -y kubectl

3. Install Minikube

Install Minikube to run your single node kubernetes cluster.

curl -Lo minikube \
  && chmod +x minikube && \
  sudo cp minikube /usr/local/bin && rm minikube

4. Done!

You can run Minikube and start your cluster by running:

minikube start

You can then see that it is running:

kubectl get nodes


Copy link

Utkarsh490 commented Nov 6, 2021

Thankyou somuch for helping us out here..


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment