I looked up the docs to understand the difference between commands docker image (managing images) and docker images (list images). So the second option seems to be a shortcut for docker image ls which also lists images.
What I noticed is, when running docker image ls or docker images I get a list of all my images as expected, but when I accidentally mixed those two up and run docker images ls I get an empty table without any entries:
REPOSITORY TAG IMAGE ID CREATED SIZE
I would expect it either to be an invalid command since it is redundant or to show the same list of all my images.
So what does docker images ls actually show?
docker image ls lists the imagesdocker images also lists the imagesdocker images ls lists the images with the repository name ls. And as you dont have any images named ls it is returning an empty list.Reference : https://docs.docker.com/engine/reference/commandline/images/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With