Minikube is set up within a single VM and it is very useful if you have limited resources, Minikube is not used for production environment setup, it is mostly used by the developers or to set up an environment for learning.
Note: To setup the k8 using minikube we will need a virtual box.
Minikube installation on Windows platform
- Open official documentation of the k8s (https://kubernetes.io/docs/tasks/tools/install-kubectl-windows/)
- Check for virtualization setting with the help of systeminfo command
Output Should be like this
Hyper-V Requirements: VM Monitor Mode Extensions: Yes Virtualization Enabled In Firmware: Yes Second Level Address Translation: Yes Data Execution Prevention Available: Yes
- Now Download the latest release of Kubectl with the help of the below command
curl -LO "https://dl.k8s.io/release/v1.22.0/bin/windows/amd64/kubectl.exe"
- Download the latest Release of Minikube with the help of the below command
curl -Lo minikube.exe https://github.com/kubernetes/minikube/releases/latest/download/minikube-windows-amd64.exe New-Item -Path "c:\" -Name "minikube" -ItemType "directory" -Force Move-Item .\minikube.exe c:\minikube\minikube.exe -Force
- Move the downloaded binary to C drive(rename above-downloaded binary to minikube.exe)
- Setup environment variable with the help of the above-created path
- Now hit minikube start command(this will launch a VM in a virtual box, which will have a k8 running inside it)
- Test the setup using the below command
kubectl get pods
it will list the pods running
- To ssh the above-created cluster we will use putty for the windows machine, launch putty in your windows machine, and put the above IP in it, it will ask for username and password. The default username and password for minikube VM is docker and tcuser.
- If you wish to launch dashboard for minikube, we can use the below command
this will launch the dashboard to show the resources created in the k8 cluster)