Install Docker via Command Line

This documentation details two ways to install Docker via the Command Line. As there are many different server configurations using Linux, this list is non-exhaustive, and we recommend following the process that best suits Your System.

Install Docker on AWS EC2

  1. Run sudo yum update -y .
  2. Run sudo yum install docker -y.
  3. Run sudo service docker start.
  4. Download and Install Compose CLI Plugin.
    $ DOCKER_CONFIG=${DOCKER_CONFIG:-$HOME/.docker}
    $ mkdir -p $DOCKER_CONFIG/cli-plugins
    $ curl -SL https://github.com/docker/compose/releases/download/v2.20.0/docker-compose-linux-x86_64 -o $DOCKER_CONFIG/cli-plugins/docker-compose
    
  5. Update permissions to make the plugin executable.
    chmod +x $DOCKER_CONFIG/cli-plugins/docker-compose
  6. Run cd /usr/local/bin.
  7. Run sudo groupadd docker.
  8. Run sudo usermod -aG docker ec2-user.
  9. Close and reenter remote terminal to ensure user and group changes are made.

Install Docker on Microsoft Azure

Important Note: Some commands may need super user privileges (sudo).

To install Docker on Microsoft Azure, you can follow the same steps found in Docker's Ubuntu Installation Manual.