Created
March 1, 2022 03:45
-
-
Save diegolovison/63fa3eec1419210429150cdeb76d5d36 to your computer and use it in GitHub Desktop.
How retrieve OpenShift registry
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
oc login ... | |
OC_USER=$(oc whoami) | |
oc project openshift-image-registry | |
oc patch configs.imageregistry.operator.openshift.io/cluster --patch '{"spec":{"defaultRoute":true}}' --type=merge | |
oc policy add-role-to-user registry-viewer $OC_USER | |
oc policy add-role-to-user registry-editor $OC_USER | |
REGISTRY_HOST=$(oc get route default-route --template='{{ .spec.host }}') | |
echo $REGISTRY_HOST |
Author
diegolovison
commented
Mar 14, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment