How to List Docker Images in Linux Ubuntu 19.10 Operating System

Posted on

In this article, there will be just one main focus discussion. It is only discussing about how to list the docker images. Every docker container will use a docker images. For a more suitable answer, there is a further explanation in this link. In that link,  an instance of an image is called a container. You have an image, which is a set of layers as you describe. If you start this image, you have a running container of this image. You can have many running containers of the same image. As in another article, in order to see or to list all the available containers, just execute the command ‘ps -a’. The article exist in this link.  By default You can see all your images with docker images whereas you can see your running containers with docker ps (and you can see all containers with docker ps -a).

It will be a different case if the one for further listing are images. There are other specific command for listing the available docker images. Just execute the following command in order to be able to list any available docker images :

root@hostname:~# docker images
REPOSITORY           TAG                 IMAGE ID            CREATED             SIZE
mysql/mysql-server   5.7                 c8c8ef4f3c81        2 months ago        310MB

As it exist in the output of the above command execution, it will definitely list all the available images in the machine. According to the above output of the command execution, there is only one docker image available. That docker image is a MySQL Database Server with the version of 5.7. So, with the available docker images exist in the local machine, the docker can run a container using the image. By running the container using the image, it will provide the functionality own by a MySQL Database Server. In order to run the image using docker so that it will become a docker container with a purpose, just execute it using command ‘docker run’.

One thought on “How to List Docker Images in Linux Ubuntu 19.10 Operating System

Leave a Reply