Skip to content

Instantly share code, notes, and snippets.

@smartexpert
Last active February 18, 2022 13:58
Show Gist options
  • Save smartexpert/4df8a73d45d70611103ddb17271df03f to your computer and use it in GitHub Desktop.
Save smartexpert/4df8a73d45d70611103ddb17271df03f to your computer and use it in GitHub Desktop.
docker setup in digital ocean
## All lines have to be run separately
## Install docker
sudo apt update -y && sudo apt install apt-transport-https ca-certificates curl software-properties-common -y && curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu focal stable" -y && sudo apt update -y && apt-cache policy docker-ce && sudo apt install docker-ce -y
sudo systemctl status docker
## Setup docker compose
sudo curl -L "https://github.com/docker/compose/releases/download/v2.2.3/docker-compose-$(uname -s | awk '{print tolower($0)}')-$(uname -m)" -o /usr/local/bin/docker-compose &&
sudo chmod +x /usr/local/bin/docker-compose && docker-compose --version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment