To use Red Hat subscriptions within a build, you should create an ImageStream
to reference the universal base image (UBI).
Builds that reference the UBI directly from registry.redhat.io will require a pull secret.
Prerequisites
-
You must create a pull secret for registry.redhat.io, and link it to a user project.
Procedure
-
To create an
imagestreamtag
in a single project:$ oc tag --source=docker registry.redhat.io/ubi7/ubi:latest ubi:latest
-
To create an
imagestreamtag
in the {product-title} namespace, making it available to developers in all projects:$ oc tag --source=docker registry.redhat.io/ubi7/ubi:latest ubi:latest -n openshift