Skip to content

Instantly share code, notes, and snippets.

@t04glovern
Created May 1, 2020 12:54
Show Gist options
  • Save t04glovern/484ad9f182970984933ed92cf5cf722f to your computer and use it in GitHub Desktop.
Save t04glovern/484ad9f182970984933ed92cf5cf722f to your computer and use it in GitHub Desktop.
michalgutowski/cka-lab Bootstrap
# on ckamaster1
sudo -i
apt install docker.io kubeadm=1.15.1-00 kubectl=1.15.1-00 kubelet=1.15.1-00
kubeadm init --config=kubeadm-config.yaml --upload-certs| tee kubeadm-init.out
## OUTPUT
# kubeadm join ckamaster:6443 --token 4gttsi.cpkvihy9jwb8o8aq \
# --discovery-token-ca-cert-hash sha256:c70ef81c9dd7064432a255b9f617e8c3c83b4cce64db17e2518c32b0e3aaf460
exit
mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config
# on ckaworker1
sudo -i
apt install docker.io kubeadm=1.15.1-00 kubectl=1.15.1-00 kubelet=1.15.1-00
kubeadm join ckamaster:6443 --token 4gttsi.cpkvihy9jwb8o8aq \
--discovery-token-ca-cert-hash sha256:c70ef81c9dd7064432a255b9f617e8c3c83b4cce64db17e2518c32b0e3aaf460
# on ckamaster1
sudo kubectl get nodes
# NAME STATUS ROLES AGE VERSION
# ckamaster1 NotReady master 4m53s v1.15.1
# ckaworker1 NotReady <none> 69s v1.15.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment