sudo apt-get update
sudo apt-get install apt-transport-https ca-certificates
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
- Open the /etc/apt/sources.list.d/docker.list file in your favorite editor. If the file doesn’t exist, create it.
- Remove any existing entries. Add:
deb https://apt.dockerproject.org/repo ubuntu-xenial main
then run:
sudo apt-get update
sudo apt-get purge lxc-docker
apt-cache policy docker-engine
sudo apt-get update
sudo apt-get install docker-engine
sudo service docker start
sudo docker run hello-world
sudo apt install docker-compose
sudo apt-get install python-ipaddress
sudo groupadd docker
sudo usermod -aG docker $USER