Minikube Installation
K8s Setup Requirements
8 CPUs or more
16GB of free memory
150 GB of free disk space
Internet connection
Container or virtual machine manager, such as: Docker, Hyperkit, Hyper-V, KVM, Parallels, Podman, VirtualBox, or VMware Fusion/Workstation
Install kubectl
Download the latest Kubectl release with the command:
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"chmod +x kubectlsudo mv kubectl /usr/bin/Test to ensure the version you installed is up-to-date:
kubectl versionKubectl autocomplete
BASH
source <(kubectl completion bash) # setup autocomplete in bash into the current shell, bash-completion package should be installed first.
echo "source <(kubectl completion bash)" >> ~/.bashrc # add autocomplete permanently to your bash shell.You can also use a shorthand alias for kubectl that also works with completion:
alias k=kubectl
complete -o default -F __start_kubectl kZSH
source <(kubectl completion zsh) # setup autocomplete in zsh into the current shell
echo '[[ $commands[kubectl] ]] && source <(kubectl completion zsh)' >> ~/.zshrc # add autocomplete permanently to your zsh shellInstall Kubernetes using Minikube
To install the latest minikube stable release on x86-64 Linux using Debian package:
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube_latest_amd64.debsudo dpkg -i minikube_latest_amd64.debStart the Cluster
Start your minikube cluster with one master node using the following command.
We are using Flannel Plugin for Networking, NetworkPolicy Management, Traffic Management
minikube startminikube statusCongratulations you now have a minikube cluster.
Enable Metrics Server
minikube addons enable metrics-serverEnsure your Master Node is in Healthy State and all the necessary services and pods are working fine.
Worker Nodes Creation
Note: This as an optional step, you can safely skip this step if you do not require an additional worker node.
minikube node add --worker=trueVerify nodes using the following command
kubectl get nodesRepeat the above steps, if you want to add more worker Nodes.
Kubectl context and configuration
Show Merged kubeconfig settings.
kubectl config viewDisplay list of contexts
kubectl config get-contextsLast updated