Docker community edition ubuntu

Install Docker on ubuntu for developers

Docker is a great tool for developers. The key reason why is that it removes friction incurred when setting up your development laptop for different development environments, especially for Polyglot developers!.

If you’re a developer who supports many different projects, all written in different programming languages, using different runtime libraries and frameworks in those langunages. For instance, PHP websites developed using Laravel, others using CakePHP, yet others using the YII Framework and then there are a few WordPress based websites. All using slightly different versions of the Frameworks because customers don’t want to upgrade for a variety of different reasons.

You also have to support a few Node.js applications, and we al know how often Node upgrades it’s versions. We haven’t even got into to the debate regarding myriad of the latest hot trend in JavaScript UI frameworks!

What about python? Is this app you’re working on 2.7 or 3 ? What web server is the site using ? is it Apache or Nginx? What Database Management system is it using? Is it mySQL ? MariaDB, MS SQL, PostgresSQL, Redis or MongoDB? What about the Messaging is it RabbitMQ, MSMQ or something else nobody else is using?

It can be an absolute nightmare configuring your workstation just to fix a 5 minute bug. It can take hours uninstalling tweaking, troubleshooting and reconfiguring. Time which is better spent hyping some Web Framework on Twitter!

Docker to the rescue

Docker drastically simplifies this process. Reducing the need for developers to be configuration experts enabling them to focus on the things they like doing solving problems using code!

If you’re running Mac or Windows installing Docker is a relatively simple process of quite literally following a wizard. Read instructions on how to install docker on Windows or install docker on Mac OSX. You should be up and running is minutes.

Installing docker on ubuntu

When it comes to installing docker on ubuntu, things are slightly trickier, and although the instuctions on the docker website are great and will get you up and running quickly. I have found a couple of quirks that aren’t always that obvious. I will aim to cover these and keep this post updated as I find them.

Uninstall old versions

There are a number of different versions of docker available. As with any Open Source library, they tend to go through different iterations before finally getting to a state where they either get funding and are able to market the product and get it ready for the market or they subject to the whims and desires or whoever maintains them or they just die!

Fortunately for docker, it gained mass appeal and adoption. Unfortunately most package repositories still have the much older versions of package available for public download, and a number of tutorials on the internet provide guides and tutorials for installing these older versions.

So firstly, check whether you have any older versions installed. Open a terminal window (ctrl + alt + t) and execute docker -v, if the terminal responds with anythin other than Docker version 17.05.0-ce, build 89658be then you need to remove it. If you have a higher version or build then you’re good to go.

If you have an older version installed. use dpkg -l | grep -i docker to identify the version, this should return with either : docker , docker-engine or

The completely remove and purge the package replacing [package name] with the name of the package you have installed :


Your development machine should now be ready to install Docker Communit edition . We’ll reproduce the instructions here, but please be advised these may change and we urge you to double check on the docker website.

There is a complete script to automate the installation of docker available from you can download this script and run it on your machine.

Please be aware that this install process is typical for 64-Bit laptops or Dekstops using ubuntu 16.04 LTS. If you’re installing on anything other then check the docker website

After completing the steps above you should Log out and log back into your laptop for the settings to take effect.

Run your first docker images

You should now be in state to start playing with docker.

There are three ways to test if docker is working.

1. Hello World

In typical programmer tradition we’ll run a “Hello World” application docker style.

To run the Hello-World sample, open a terminal window (ctrl + alt + t) and execute docker run hello-world you should see a response similar to;

2. Busy Box

We’ll run a small embedded Linux distro called BusyBox .

BusyBox combines tiny versions of many common UNIX utilities into a single small executable. It provides replacements for most of the utilities you usually find in GNU fileutils, shellutils, etc.

The utilities in BusyBox generally have fewer options than their full-featured GNU cousins; however, the options that are included provide the expected functionality and behave very much like their GNU counterparts. BusyBox provides a fairly complete environment for any small or embedded system.

To run an instance of Busybox open a terminal window (ctrl + alt + t) and execute docker run busybox echo "hello from" and you should see result similar to:

3. Docker-whale

If you’re feeling a little more adventurous you can use the docker client to search for an image and run it. As an example, from the terminal use docker search threenine this should return a list of the docker images we have created. At the time writing this post, it returns a list of 4 images, of which the specific one of interest will be threenine/docker-whale, which is a result of following the docker tutorial for creating images.

Let’s go ahead and run that image docker run threenine/docker-whale


Docker should now be installed on your development machine and you should now be able to create and use docker images.

Follow Me

Gary Woodfine

Helps businesses by improving their technical proficiencies and eliminating waste from the software development pipelines.

A unique background as business owner, marketing, software development and business development ensures that he can offer the optimum business consultancy services across a wide spectrum of business challenges.
Follow Me

Latest posts by Gary Woodfine (see all)

%d bloggers like this: