How to install and kick off minikube on Ubuntu?
Install kubectl:
$ sudo apt update
$ sudo apt install apt-transport-https
$ curl -sSL https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -
$ echo "deb http://apt.kubernetes.io/ kubernetes-xenial main" | sudo tee -a /etc/apt/sources.list.d/kubernetes.list
$ sudo apt update
$ sudo apt install kubectlInstall VirtualBox:
$ sudo apt update
$ sudo apt install virtualbox virtualbox-ext-packInstall minikube (replace v1.17.1 with the latest version available for you):
$ wget https://github.com/kubernetes/minikube/releases/download/v1.17.1/minikube-linux-amd64
$ mv minikube-linux-amd64 minikube
$ chmod +x minikube
$ sudo cp minikube /usr/local/bin/
$ rm minikubeCreate the VM and start the cluster (this will create/update the file
~/.kube/config):
$ minikube config set driver virtualbox # Set virtualbox as the default driver
$ minikube start # use `minikube start --help` for more options
$ kubectl cluster-infoTo get the IP address of the cluster:
$ minikube ip
$ sudo -e /etc/hosts # if you want to assign names to this IP addressTo show the Minikube dashboard:
$ minikube dashboardTo stop the cluster (shuts down the VM and preserve all states):
$ minikube stopTo restart the VM and cluster:
$ minikube startTo delete the cluster (and the VM):
$ minikube delete