Creating a single control-plane cluster with kubeadm
Install and Deploy Kubernetes on Ubuntu 18.04 LTS
make sure to pass this parameter on init if you want to use flannel:
--pod-network-cidr=10.244.0.0/16
After all dependencies are installed and swap has been disabled:
sudo kubeadm init --pod-network-cidr=10.244.0.0/16 --kubernetes-version=1.18.2
mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config