OpenShift Container Storage is now OpenShift Data Foundation starting with version 4.9.
Este conteúdo não está disponível no idioma selecionado.
Chapter 2. Building and mirroring the Red Hat operator catalog
Follow this process on a host that has access to Red Hat registries to create a mirror of those registries.
Prerequisites
- Run these commands as a cluster administrator.
-
Be aware that mirroring the
redhat-operatorcatalog can take hours to complete, and requires substantial available disk space on the mirror host.
Procedure
Build the catalog for
redhat-operators.Match the tag of the
ose-operator-registryin the--fromflag to the major and minor versions of the OpenShift Container Platform cluster (for example,4.6).oc adm catalog build --appregistry-org redhat-operators \ --from=registry.redhat.io/openshift4/ose-operator-registry:v4.6 \ --from=registry.redhat.io/openshift4/ose-operator-registry:v4.6 \ --to=${MIRROR_REGISTRY_DNS}/olm/redhat-operators:v1 \ --to=${MIRROR_REGISTRY_DNS}/olm/redhat-operators:v1 \ --registry-config=${AUTH_FILE} \ --registry-config=${AUTH_FILE} \ --filter-by-os="linux/amd64" --insecure --filter-by-os="linux/amd64" --insecure$ oc adm catalog build --appregistry-org redhat-operators \ --from=registry.redhat.io/openshift4/ose-operator-registry:v4.6 \ --to=${MIRROR_REGISTRY_DNS}/olm/redhat-operators:v1 \ --registry-config=${AUTH_FILE} \ --filter-by-os="linux/amd64" --insecureCopy to Clipboard Copied! Toggle word wrap Toggle overflow Mirror the catalog for
redhat-operators.This is a long operation and can take 1-5 hours. Make sure there is 100 GB available disk space on the mirror host.
oc adm catalog mirror ${MIRROR_REGISTRY_DNS}/olm/redhat-operators:v1 \ ${MIRROR_REGISTRY_DNS} --registry-config=${AUTH_FILE} --insecure ${MIRROR_REGISTRY_DNS} --registry-config=${AUTH_FILE} --insecure$ oc adm catalog mirror ${MIRROR_REGISTRY_DNS}/olm/redhat-operators:v1 \ ${MIRROR_REGISTRY_DNS} --registry-config=${AUTH_FILE} --insecureCopy to Clipboard Copied! Toggle word wrap Toggle overflow Disable the default
OperatorSourcesby addingdisableAllDefaultSources: trueto thespecfile for the Operator Hub.oc patch OperatorHub cluster --type json -p '[{"op": "add", "path": "/spec/disableAllDefaultSources", "value": true}]'$ oc patch OperatorHub cluster --type json -p '[{"op": "add", "path": "/spec/disableAllDefaultSources", "value": true}]'Copy to Clipboard Copied! Toggle word wrap Toggle overflow