Cloud Experts Documentation

Accessing the Internal Registry from ARO

This content is authored by Red Hat experts, but has not yet been tested on every supported configuration.

Kevin Collins

06/28/2022

One of the advantages of using OpenShift is the internal registry that comes with OpenShfit to build, deploy and manage container images locally. By default, access to the registry is limited to the cluster ( by design ) but can be extended to usage outside of the cluster. This guide will go through the steps required to access the OpenShift Registry on an ARO cluster outside of the cluster.

Prerequisites

  • an ARO Cluster
  • oc cli
  • podman or docker cli

Expose the Registry

  1. Expose the registry service

    oc create route reencrypt --service=image-registry -n openshift-image-registry
    
  2. Annotate the route

    oc annotate route image-registry haproxy.router.openshift.io/balance=source -n openshift-image-registry
    
  3. Get the route host name

    HOST=$(oc get route image-registry -n openshift-image-registry --template='{{ .spec.host }}')
    
  4. Log into the image registry

    podman login -u $(oc whoami) -p $(oc whoami -t) $HOST
    

Test it out

podman pull openshift/hello-openshift

podman images

expected output

 openshift/hello-openshift                                   latest    7af3297a3fb4   4 years ago    6.09MB

Interested in contributing to these docs?

Collaboration drives progress. Help improve our documentation The Red Hat Way.

Red Hat logo LinkedIn YouTube Facebook Twitter

Products

Tools

Try, buy & sell

Communicate

About Red Hat

We’re the world’s leading provider of enterprise open source solutions—including Linux, cloud, container, and Kubernetes. We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Subscribe to our newsletter, Red Hat Shares

Sign up now
© 2023 Red Hat, Inc.