Skip to content

Instantly share code, notes, and snippets.

@kostyll
Last active December 29, 2017 08:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kostyll/53473c8c248659e0b1cdba2d92356c76 to your computer and use it in GitHub Desktop.
Save kostyll/53473c8c248659e0b1cdba2d92356c76 to your computer and use it in GitHub Desktop.
docker docker-compose installation (+tmux mosh)
#!/bin/bash
echo "general install ..."
apt-get update && apt-get install rsync tmux mosh wget curl -y
apt-get install \
apt-transport-https \
ca-certificates \
curl \
gnupg2 \
software-properties-common \
-y
echo "preparing docker install..."
curl -fsSL https://download.docker.com/linux/$(. /etc/os-release; echo "$ID")/gpg | apt-key add -
apt-key fingerprint 0EBFCD88
add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/$(. /etc/os-release; echo "$ID") \
$(lsb_release -cs) \
stable"
apt-get update
echo "installing docker ...."
apt-get install docker-ce -y
echo "running hello-world ..."
docker run hello-world
echo "installing docker-compose ...."
curl -L https://github.com/docker/compose/releases/download/1.18.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
docker-compose --version
echo "installed!"
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment