0

I know we can add registry name before image name. like docker pull my_registry/myimage:latest. But by default it looks in docker hub. Is there anyway to remove docker hub from default or add a prefix for pulling image so if I try docker pull redis, it automatically runs docker pull myrepo/redis ?

I want to do it in openshift 4.7

enter image description here

As you see I want to look for redis in my private registry without adding my_registry/redis.

Thank you so much.

BMitch
  • 5,189
  • 1
  • 21
  • 30
  • Did you try [this solution](https://docs.openshift.com/container-platform/3.11/install_config/registry/extended_registry_configuration.html#whitelisting-docker-registries)? Remember to use a proper fields names, like `[registries.search]` or `[registries.insecure]`. – Mikolaj S. Jan 05 '22 at 09:04
  • I would recommend against trying to change the default registry name, you will introduce multiple security risks. https://www.redhat.com/en/blog/be-careful-when-pulling-images-short-name – BMitch Jan 05 '22 at 14:20

0 Answers0