Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Docker Kubernetes Vagrant Script
sudo apt update
sudo apt -y dist-upgrade
sudo apt install -y apt-transport-https ca-certificates curl software-properties-common
curl -fsSL | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] xenial stable"
sudo apt update
apt-cache policy docker-ce
sudo apt install -y docker-ce
sudo systemctl status docker
sudo usermod -aG docker ${USER}
sudo apt-get update \
&& curl -s | sudo apt-key add -
# bionic 18.04 not yet available, so use 16.04 (xenial)
echo "deb kubernetes-xenial main" \
| sudo tee -a /etc/apt/sources.list.d/kubernetes.list \
&& sudo apt-get update
sudo apt install -y kubeadm kubelet kubernetes-cni=0.6.0-00
# kubelet requires swap off
sudo swapoff -a
# keep swap off after reboot
sudo sed -i '/ swap / s/^\(.*\)$/#\1/g' /etc/fstab
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.