Friday, May 13, 2016

How to install Docker on Lubuntu

Deploying software can be frustrated, luckily we have docker, docker allow us to deploy software efficiently across all environment. In this article i will show you how to install docker on lubuntu.

To install docker on lubuntu is very easy, simply open terminal/ console/ command prompt (press CTRL + ALT + T) and then run this command:

sudo apt-get install

There are two packages on lubuntu 15.10 that related to docker, one is docker and the other is, the correct one is

Alright, now let's try run docker command, let's take a look at the docker version we currently have, the command is docker version.

sudo docker version

For some reasons, if you run docker without sudo it will shows error permission denied, so always run docker with sudo command otherwise it won't work.

FATA[0000] Get http://%2Fvar%2Frun%2Fdocker.sock/v1.18/version: dial unix /var/run/docker.sock: connect: permission denied. Are you trying to connect to a TLS-enabled daemon without TLS? 

Next try run docker images, to see what images available on the system, it should show no image since we just install docker.

sudo docker images 

Okay, let's try run hello world docker, on the command line type sudo docker run hello-world, if the image doesn't exists it will download from docker hub.

sudo docker run hello-world

If you can run the hello world then docker is ready to use, try different images such as ubuntu, run this command to get the ubuntu image.

sudo docker run -it ubuntu bash

No comments:

Post a Comment