oc mirror fails with "authenticationrequired" error when connecting to registry.redhat.io
Issue
-
The
oc mirrorfails to mirror the images from theregistry.redhat.ioregistry with the following error, even when the correct username and password for the Red Hat registry are used.:Error: authenticating creds for "registry.redhat.io": pinging container registry registry.redhat.io: Get "[https://registry.redhat.io/v2/](https://registry.redhat.io/v2/)": authenticationrequired
Environment
- Red Hat OpenShift Container Platform (RHOCP)
- 4
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.