Installing docker and docker-machine on Ubuntu
Contents
I want to be able to quickly spin up game servers for small sessions and tear
them down afterwards. Online investigation reveals that docker-machine
paired with DigitalOcean as a provider might be just what is needed. That claim
needs to be tested, but a pre-requisite is that the docker
and
docker-machine
tools be available on the local system. This post will
describe how to install them on an Ubuntu box.
Repository setup
First we need to get all our dependencies installed,
|
|
The purpose of installing the above is to allow the apt
command to be able
to fetch repositories over HTTPS. Next we need to grab Docker’s official GPG
key,
|
|
It will be good to manually verify that we have the correct key with the
following fingerprint = 9DC8 5822 9FC7 DD38 854A E2D8 8D81 803C 0EBF CD88
.
We can search for installed fingerprints by the last few characters,
|
|
Finally, we can use the following command to setup the stable repository,
|
|
Installing Docker Engine
With the above done, it becomes very straight-forward to install the docker engine with the following command,
|
|
Installing Docker Machine
Strangely enough, the official suggestion is to download the Docker Machine binary and extract it to the user’s PATH via this command,
|
|
At the time of typing, the lastest version for docker-machine
is 0.16.2
.