Install Docker and docker-compose on Raspberry Pi

Installing Docker requires adding the a repository with the updated version:

sudo apt update
sudo apt upgrade
sudo apt install apt-transport-https \
                 ca-certificates \
                 software-properties-common \
curl -fsSL | sudo apt-key add -
apt-key fingerprint 58118E89F3A912897C070ADBF76221572C52609D
sudo nano /etc/apt/sources.list

Add the line:

deb debian-stretch main

changing ‘stretch‘ with your version of Raspbian. You can check your version using lsb_release -cs.

sudo apt update
curl -sSL | sh
sudo usermod -aG docker pi
sudo reboot

For docker-compose, first we will need to install Berry Conda:

chmod +x
sudo reboot

And then install docker-compose using pip:

pip install docker-compose
sudo reboot