For platform-specific instructions, please consult the docker official documentation.
Alternative way of docker installation on Linux (Ubuntu, CentOS, ...)
$ curl -fsSL https://get.docker.io | sh
type your password to install docker.
By default, you need sudo to execute docker commands.
To do so without sudo, add yourself to the system docker
group.
$ sudo usermod -aG docker $USER
It will work after restarting your login session.
You need to install docker-compose separately.
Check out the official documentation.
Check out the official repository for instructions.