Skip to content

Instantly share code, notes, and snippets.

@habibiefaried
Last active July 11, 2019 13:22
Show Gist options
  • Save habibiefaried/6a9dd7b116cb18c74ad96dd0cfbdb096 to your computer and use it in GitHub Desktop.
Save habibiefaried/6a9dd7b116cb18c74ad96dd0cfbdb096 to your computer and use it in GitHub Desktop.
Install kubernetes
Reference: https://kubernetes.io/docs/setup/production-environment/tools/kubeadm/high-availability/
1. Set /proc/sys/net/bridge/bridge-nf-call-iptables to 1 by running sysctl net.bridge.bridge-nf-call-iptables=1 to pass bridged IPv4 traffic to iptables’ chains.
2. Ubuntu 18.04
3. Disable swap
4. Install docker
https://kubernetes.io/docs/setup/production-environment/container-runtimes/#docker
5. Disable firewall / Allow all access
6. Install kubeadm and kubelet
apt-get update && apt-get install -y apt-transport-https curl
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
cat <<EOF >/etc/apt/sources.list.d/kubernetes.list
deb https://apt.kubernetes.io/ kubernetes-xenial main
EOF
apt-get update
apt-get install -y kubelet kubeadm kubectl
apt-mark hold kubelet kubeadm kubectl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment