Docker Search

To search a image on docker remote registry you can use docker search command.

Example: docker search ubuntu
ubuntu   Ubuntu is a Debian-based Linux operating s...   4482   [OK]       
ubuntu-upstart   Upstart is an event-based replacement for ...   65   [OK]       
rastasheep/ubuntu-sshd   Dockerized SSH service, built on top of of...   32  [OK]
torusware/speedus-ubuntu   Always updated official Ubuntu docker imag...   27   [OK]

This example displays images with a name containing ubuntu. First column displays the name of image. You may notice rastasheep/ubuntu-sshd has a / in the name. The left portion i.e. rastasheep is the username and right portion i.e. ubuntu-sshd is the image name. Some image does not have a / in the name, just like the first one i.e. ubuntu. In this case library is the username

Note: Search queries will only return up to 25 results. You can use --limit option to change the search result display limit.

Docker pull

docker pull is the command to pull docker image from remote registry. docker pull debian
Using default tag: latest
latest: Pulling from library/debian

This will try to pull the image with latest tag.

List first 10 tags

Listing all the available tag can be tricky. Well that information is always available on the image info page on There are lot of cases that you may need this information using a command line. This can be done using a simple API call and parsing the json output using jq tool. curl ''|jq '."results"[]["name"]'

Note: jq is a tool for processing JSON inputs. jq is like sed for JSON data - you can use it to slice and filter and map and transform structured data with the same ease that sed, awk, grep and friends let you play with text.

A script to List all Tags


while [ $? == 0 ]
   curl$i 2>/dev/null|jq '."results"[]["name"]'


and now debian image with a specific tag can be pulled using docker pull debian:testing

Or if you want to pull all tag of a image docker pull -a debian

Like it? Click here to Tweet your feedback