I've exposed my openshift registry:
$ oc get routes -n default
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD
docker-registry docker-registry-default.192.168.99.104.nip.io docker-registry 5000-tcp None
Nevertheless, I'm trying to get access on that registry, but I've not been able to figure out what's wrong:
docker login -p ngRslZJYJ40WxBA6YQbE5nMDK1Gh-cSWgnJCKR4EJ2I docker-registry-default.192.168.99.104.nip.io -u unused
This command keeps stuck.
If the route is configured with HTTPS and the cert is a self-signed cert then docker has to be configured to trust the cert.
Steps:
/etc/docker/certs.d/
named after the OpenShift Docker Registry URL: mkdir -p /etc/docker/certs.d/docker-registry-default.192.168.99.104.nip.io
/etc/docker/certs.d/docker-registry-default.192.168.99.104.nip.io/ca.crt
Add the following to your host /etc/hosts
file:
<router IP> docker-registry-default.192.168.99.104.nip.io
You can get the router IP by:
oc get svc -n default
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.