Minikube and Kubectl — Setup in Linux
Minikube is a tool that helps you run Kubernetes locally on your system. You can use it for testing purposes. It is a one node cluster where the master processes & node processes run on one machine.
Minikube has the runtime container (docker) preinstalled.
Kubectl is the CLI tool for the Kubernetes cluster. We will need it installed to make our lives easier when working with k8s.
Note: For this set-up you need to have docker configured previously
Kubectl Set-up
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"curl -LO "https://dl.k8s.io/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl.sha256"echo "$(<kubectl.sha256) kubectl" | sha256sum --checksudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl
To check if everything is working fine, we can use:
kubectl version --client
Minikube Set-up
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64sudo install minikube-linux-amd64 /usr/local/bin/minikube
You can start, stop and delete your minikube cluster using the following commands:
minikube start
minikube stop
minikube delete
References:
Hope this was helpful. Thanks for reading!