Skip to content

Instantly share code, notes, and snippets.

@prikid
Last active June 24, 2022 02:12
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save prikid/b39b3f6142c85ef82494010ea378b42c to your computer and use it in GitHub Desktop.
Save prikid/b39b3f6142c85ef82494010ea378b42c to your computer and use it in GitHub Desktop.
Install docker and docker compose 2 on Ubuntu
sudo apt-get update
sudo apt-get remove docker docker-engine docker.io containerd runc
sudo apt-get install -y \
ca-certificates \
curl \
gnupg \
lsb-release \
wget
wget -O - https://get.docker.com/ | bash
sudo systemctl enable docker.service
sudo systemctl start docker.service
DOCKER_CONFIG=${DOCKER_CONFIG:-$HOME/.docker}
mkdir -p $DOCKER_CONFIG/cli-plugins
curl -SL https://github.com/docker/compose/releases/download/v2.4.1/docker-compose-linux-$(uname -m) -o $DOCKER_CONFIG/cli-plugins/docker-compose
chmod +x $DOCKER_CONFIG/cli-plugins/docker-compose
docker compose version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment