Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
How to use docker hub with podman?
Unlike docker, Podman won't (understandably) use docker hub by default. You can use it explicitly like this: (just using a random example here, it's an OpenAPI linter)
podman pull docker.io/dshanley/vacuum
But how to do it without the docker.io
prefix?
1 answer
Add the following to /etc/containers/registries.conf
:
unqualified-search-registries = ["docker.io"]
[[registry]]
location = "docker.io"
Now you can pull just like you would in docker:
podman pull dshanley/vacuum
Just note that podman defines a bunch of aliases for common containers in /etc/containers/registries.conf.d/00-shortnames.conf
which are checked before searching docker.io, so if you seem to be pulling wrong images, then you might want to delete/edit that file.
This is also a useful blog post on the subject: How to manage Linux container registries
0 comment threads