How to view Docker image layers on Docker Hub?

stackoverflower picture stackoverflower · Nov 30, 2014 · Viewed 7.7k times · Source

I know that I can use this command $ docker images --tree docker history to view the layers of a Docker image, but how do I do that for images on Docker Hub without pulling it? This is so that I know what is on an image before I download it.

E.g., for the Tomcat repo, https://registry.hub.docker.com/_/tomcat/, the webpage doesn't seem to show what is on the image. I have to look at the Dockerfile on Github to find out.

Update I see this repo https://registry.hub.docker.com/u/tutum/tomcat/ has more tabs. The "Dockerfile" tab shows how it is created, but only seems to show the latest version. Is there no choice to view the file for other tags?

Answer

Bryan picture Bryan · Nov 30, 2014

Docker Hub is quite limited at the moment and does not offer the feature you asked for.

When an image is configured to build from source at Docker Hub (an Automated Build) you can see what went into it, but when it is uploaded pre-built you have no information.