Instead of using docker use docker.io
sudo apt-get install docker.io
Why install docker on ubuntu should be `sudo apt-get install docker.io`?
Why do Ubuntu use docker.io as executable name instead of just docker? Tutorials, blog posts all now have to mention this difference, “if you use Ubuntu 14.04, or if you are with rest of the world (including earlier versions of Ubuntu)”. Why?
This is because of a Debian/Ubuntu policy; there is already a program called “docker” , and it was not allowed to use the same binary name.