Note: This is only tested on OCP 4.3 or 4.4 clusters
oc patch OperatorHub cluster --type json \
-p '[{"op": "add", "path": "/spec/disableAllDefaultSources", "value": true}]'
oc apply -f imageContentSourcePolicy.yaml
At this point, the nodes will go through rolling reboots to make this ImageContentSourcePolicy take effect. This usually takes 10 minutes or so, and the cluster will timeout, give you authentication errors, and all kinds of other weidr things during this time. Once all the nodes are Ready and don't show SchedulingDisabled, then it should be safe to proceed.
oc get nodes
NAME STATUS ROLES AGE VERSION
ip-10-0-138-133.us-west-1.compute.internal Ready worker 25m v1.16.2
ip-10-0-140-104.us-west-1.compute.internal Ready master 34m v1.16.2
ip-10-0-140-119.us-west-1.compute.internal Ready master 34m v1.16.2
ip-10-0-140-211.us-west-1.compute.internal Ready worker 24m v1.16.2
ip-10-0-152-146.us-west-1.compute.internal Ready master 33m v1.16.2
ip-10-0-153-246.us-west-1.compute.internal Ready worker 25m v1.16.2
oc apply -f stageCatalogSource.yaml
Alternatively, copy/paste the YAMLs into the OpenShift Console by clicking the "+" in the top right and pasting the appropiate yamls in.
Give that a couple of minutes for the new CatalogSource to come up and then ensure you have similar (but not identical) output to the below for each command:
# oc get pods -n openshift-marketplace
NAME READY STATUS RESTARTS AGE
marketplace-operator-75f49679d7-qzvb5 1/1 Running 0 17m
operators-stage-grvc7 1/1 Running 0 2m14s
# oc get catalogsource -n openshift-marketplace
NAME DISPLAY TYPE PUBLISHER AGE
operators-stage Red Hat Operators Stage Catalog grpc grpc 2m34s
# oc get packagemanifest -n openshift-marketplace
NAME CATALOG AGE
amq-streams Red Hat Operators Stage Catalog 2m58s
kubevirt-hyperconverged Red Hat Operators Stage Catalog 2m58s
kiali-ossm Red Hat Operators Stage Catalog 2m58s
serverless-operator Red Hat Operators Stage Catalog 2m58s
ocs-operator Red Hat Operators Stage Catalog 2m58s
amq-online Red Hat Operators Stage Catalog 2m58s
codeready-workspaces Red Hat Operators Stage Catalog 2m58s
performance-addon-operator Red Hat Operators Stage Catalog 2m58s
3scale-operator Red Hat Operators Stage Catalog 2m58s
openshiftansibleservicebroker Red Hat Operators Stage Catalog 2m58s
dv-operator Red Hat Operators Stage Catalog 2m58s
apicast-operator Red Hat Operators Stage Catalog 2m58s
metering-ocp Red Hat Operators Stage Catalog 2m58s
cam-operator Red Hat Operators Stage Catalog 2m58s
amq7-cert-manager Red Hat Operators Stage Catalog 2m58s
businessautomation-operator Red Hat Operators Stage Catalog 2m58s
amq-broker Red Hat Operators Stage Catalog 2m58s
openshifttemplateservicebroker Red Hat Operators Stage Catalog 2m58s
fuse-apicurito Red Hat Operators Stage Catalog 2m58s
ptp-operator Red Hat Operators Stage Catalog 2m58s
rh-service-binding-operator Red Hat Operators Stage Catalog 2m58s
eap Red Hat Operators Stage Catalog 2m58s
jaeger-product Red Hat Operators Stage Catalog 2m58s
elasticsearch-operator Red Hat Operators Stage Catalog 2m58s
fuse-online Red Hat Operators Stage Catalog 2m58s
servicemeshoperator Red Hat Operators Stage Catalog 2m58s
amq-broker-lts Red Hat Operators Stage Catalog 2m58s
amq-broker-rhel8 Red Hat Operators Stage Catalog 2m58s
e2e-test-operator Red Hat Operators Stage Catalog 2m58s
local-storage-operator Red Hat Operators Stage Catalog 2m58s
amq7-interconnect-operator Red Hat Operators Stage Catalog 2m58s
cluster-logging Red Hat Operators Stage Catalog 2m58s
sriov-network-operator Red Hat Operators Stage Catalog 2m58s
datagrid Red Hat Operators Stage Catalog 2m58s
service-binding Red Hat Operators Stage Catalog 2m58s
nfd Red Hat Operators Stage Catalog 2m58s