Skip to content

Instantly share code, notes, and snippets.

@cenkc
Created January 21, 2020 06:29
Show Gist options
  • Save cenkc/52494a7bbd44103d2e5498e2dd71f198 to your computer and use it in GitHub Desktop.
Save cenkc/52494a7bbd44103d2e5498e2dd71f198 to your computer and use it in GitHub Desktop.
1) go to https://get.docker.com/
2) download the "get-docker.sh" script as mentioned in the very first paragraph:
$ curl -fsSL https://get.docker.com -o get-docker.sh
3) then run the script:
$ sh get-docker.sh
4) If you would like to use Docker as a non-root user, you should now consider adding your user to the "docker" group with something like:
$ sudo usermod -aG docker cenkc
5) check if installation successful
$ sudo docker version
6) then go to https://docs.docker.com/machine/install-machine/ and install docker machine using command:
$ base=https://github.com/docker/machine/releases/download/v0.16.0 &&
curl -L $base/docker-machine-$(uname -s)-$(uname -m) >/tmp/docker-machine &&
sudo mv /tmp/docker-machine /usr/local/bin/docker-machine &&
chmod +x /usr/local/bin/docker-machine
7) check if installation successful
$ docker-machine version
8) to install docker-compose, you can either go to https://docs.docker.com/compose/install/ or https://github.com/docker/compose/releases.
the main difference is, github will provide the very last version. command will look like this:
$ sudo curl -L "https://github.com/docker/compose/releases/download/1.25.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
and then you need to apply executable permissions to the binary:
$ sudo chmod +x /usr/local/bin/docker-compose
9) check if installation successful
$ docker-machine version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment