Forked from carlosedp/install_container_service.sh
Last active
August 26, 2019 07:46
-
-
Save Qquanwei/a429d7e8ee1c4209cab0e81ab4735425 to your computer and use it in GitHub Desktop.
Install Container services (Docker/Kubernetes) on Debian/Ubuntu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "Container Linux installation script" | |
echo "This will install:" | |
echo " - Docker Community Edition" | |
echo " - Docker Compose" | |
echo " - Kubernetes: kubeadm, kubelet and kubectl" | |
echo "" | |
set -xeo pipefail | |
apt-get update -y | |
apt-get install -y \ | |
apt-transport-https \ | |
ca-certificates \ | |
curl \ | |
software-properties-common | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add - | |
add-apt-repository \ | |
"deb https://download.docker.com/linux/$(. /etc/os-release; echo "$ID") \ | |
$(lsb_release -cs) \ | |
stable" | |
curl -s https://raw.githubusercontent.com/Qquanwei/install-rancher-repo/master/google.gpg | apt-key add - | |
cat <<EOF >/etc/apt/sources.list.d/kubernetes.list | |
deb http://apt.kubernetes.io/ kubernetes-xenial main | |
EOF | |
apt-get update -y | |
apt-get install -y docker-ce docker-compose kubelet kubeadm kubectl | |
usermod -aG docker ${USER} | |
snap install helm --classic |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment