Installing Kubernetes
- K8s can be installed on a single node to set up the developer environments.
- minikube
- On production environments we would be using a multi node setup
- For IOT / ARM processers => K3s (Lightweight kuberenetes)
- Kubeadmin (multi node setup on linux workloads)
- Kops Refer Here for installing k8s on AWS
- kubespray Refer Here
- Native Kubernetes on Cloud
- AKS (Azure Kubernetes Services)
- GKE (Google Kubernetes Engine)
- EKS (Elastic Kubernetes Services on AWS)
- Lets try to setup
- minikube
- kubeadm
Minikube
- This is a tool to set up a single node cluster and suitable for local environments.
- To setup minikube Refer Here
- Commands
choco install minikube -y
minikube start

- Check the nodes

- Check all the pods

Kubeadm
- In this article we will be creating a kubernetes cluster on multiple linux nodes using kubeadm Refer Here
- We would be creating a 3 node kubernetes cluster

- Lets follow the installation guide Refer Here
- Install container runtime on the nodes. Lets use docker container Refer Here
- Now install kubeadm, kubectl and kubelet by following instructions Refer Here

- Now lets install pod network
kubectl apply -f "https://cloud.weave.works/k8s/net?k8s-version=$(kubectl version | base64 | tr -d '\n')"

- Now lets login into the node become a root user and execute the kubeadm join command
kubeadm join 10.128.0.49:6443 --token <somtoken>

- Now login into k8s master and execute
kubectl get nodes

- Summary of installation
- Install docker on the nodes (both) and execute the steps mentioned in Refer Here

- Install the kubeadm, kubelet and kubectl on both nodes Refer Here

- Now initialize the kubeadm by loggin in as root user on master node
kubeadm init- Copy the commands to configure the kubectl and join command

- Now become the non root user and execute the following

- Now install a pod network on master node and verify if the node is in ready state by executing kubectl get nodes
kubectl apply -f "https://cloud.weave.works/k8s/net?k8s-version=$(kubectl version | base64 | tr -d '\n')"- Now login into node and become root user (sudo -i) and execute the join command

- Now login into master node and execute kubectl get nodes to see the status of both nodes
- Install docker on the nodes (both) and execute the steps mentioned in Refer Here
