Docker

Install necessary tools:

sudo apt install apt-transport-https ca-certificates curl software-properties-common -y

Add Docker key:

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

Add Docker repo (choose the correct repository):

32bit / 64bit OS

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

ARM 32bit

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

ARM 64bit

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

Switch to correct repo:

apt-cache policy docker-ce

Install Docker:

sudo apt install docker-ce -y

If you are not root, run this to allow using Docker without sudo in the future:

sudo usermod -aG docker ${USER}

Install Docker-Compose

sudo curl -L "https://github.com/docker/compose/releases/download/1.27.4/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose

Set permission:

sudo chmod +x /usr/local/bin/docker-compose

Done. Easy!