Docker

1 min read

Docker

Technical requirements

  • Ubuntu 18.04 server instance
  • 4 GB to 8 GB of RAM

Installing Docker on Ubuntu

Let's install Docker

Update the package index by executing

sudo apt-get update

Add any packages that may be missing on the host system to allow HTTPS apt access

sudo apt-get install apt-transport-https ca-certificates curl gnupg-agent software-properties-common

Add the keys, to pull packages from Docker's repository

curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add –

Add Docker's repository to the host system

sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"

Install Docker on the server instance

sudo apt-get update sudo apt-get install docker-ce docker-ce-cli containerd.io

Start Docker and enable it on startup

sudo systemctl enable docker && systemctl start docker

Granting Docker permissions

sudo groupadd docker sudo usermod -aG docker $USER

Run the standard Docker image

docker run hello-world
Orestis Pantazos

Orestis Pantazos

DevOps Engineer