I'm not able to filter images from client.images.list()
https://docker-py.readthedocs.io/en/stable/images.html#docker.models.images.ImageCollection.list
The documentation says "name (str) – Only show images belonging to the repository name"
client.images.list(name="elixir")
EXPECTATION:
[<Image: 'elixir:1.10-alpine'>]
ACTUAL:
[<Image: 'postgres:latest'>, <Image: 'node:15-alpine'>, <Image: 'elixir:1.10-alpine'>, <Image: 'nginx:stable-alpine'>]
Bug?
Versions:
Docker version 20.10.0, build 7287ab3
>>> import docker
>>> docker.__version__
'4.4.0'
I had to use:-
To return a list of images, Martins response appears to be missing the 's' off images