3.5.2. 使用 CLI 卸载 OpenShift Update Service Operator
您可以使用 OpenShift CLI(oc)卸载 OpenShift Update Service Operator。
先决条件
- 所有 OpenShift Update Service 应用都已删除。
流程
更改到包含 OpenShift Update Service Operator 的项目,如
openshift-update-service:$ oc project openshift-update-service输出示例
Now using project "openshift-update-service" on server "https://example.com:6443".获取 OpenShift Update Service Operator operator 组的名称:
$ oc get operatorgroup输出示例
NAME AGE openshift-update-service-fprx2 4m41s删除 operator 组,如
openshift-update-service-fprx2:$ oc delete operatorgroup openshift-update-service-fprx2输出示例
operatorgroup.operators.coreos.com "openshift-update-service-fprx2" deleted获取 OpenShift Update Service Operator 订阅的名称:
$ oc get subscription输出示例
NAME PACKAGE SOURCE CHANNEL update-service-operator update-service-operator updateservice-index-catalog v1使用上一步中的
Name值,在currentCSV字段中检查订阅的 OpenShift Update Service Operator 的当前版本:$ oc get subscription update-service-operator -o yaml | grep " currentCSV"输出示例
currentCSV: update-service-operator.v0.0.1删除订阅,如
update-service-operator:$ oc delete subscription update-service-operator输出示例
subscription.operators.coreos.com "update-service-operator" deleted使用上一步中的
currentCSV值删除 OpenShift Update Service Operator 的 CSV:$ oc delete clusterserviceversion update-service-operator.v0.0.1输出示例
clusterserviceversion.operators.coreos.com "update-service-operator.v0.0.1" deleted