Stand up Kubernetes
We will install Calico on a Kubernetes cluster. To demonstrate a highly available Calico control plane, we will use five nodes in this guide. This lab walks you through provisioning a Kubernetes cluster in AWS using kubeadm.
Provision EC2 Nodes
- Provision five nodes
- Ubuntu 20.04 LTS - Focal
- Ensure the instances are in the same subnet, and security group policy allows them communicate freely with one another.
- Disable Source / Destination Checks on the Elastic Network Interface for each instance
- Install Docker on each node
sudo apt update
sudo apt install docker.io
sudo systemctl enable docker
Install kubeadm, kubelet, kubectl by following official documentation
Choose one node as your Kubernetes master. On that node
sudo kubeadm init --pod-network-cidr=192.168.0.0/16
pod-network-cidris the IP prefix for all pods in the Kubernetes cluster. This range must not clash with other networks in your VPC.
On all other nodes
sudo kubeadm join <output from kubeadm init>
Copy admin credentials
kubectl get nodes
Verify all nodes have joined. At this point nodes have joined but they are in
NotReadystate, because Kubernetes can't find a networking provider and configuration.