This documentation is for a release that is no longer maintained
See documentation for the latest supported version 3 or the latest supported version 4.6.3. Uninstalling the web terminal
Uninstalling the web terminal is a two-step process:
- Delete the components and custom resources (CRs) that were added when you installed the Operator.
- Uninstall the Web Terminal Operator.
Uninstalling the Web Terminal Operator does not remove any of its custom resource definitions (CRDs) or managed resources that are created when the Operator is installed. These components must be manually uninstalled for security purposes. Removing these components also allows you to save cluster resources by ensuring that terminals do not idle when the Operator is uninstalled.
Prerequisites
-
Access to an OpenShift Container Platform cluster using an account with
cluster-admin
permissions.
Use the CLI to delete the CRs that are created during installation of the Web Terminal Operator.
Procedure
Run the following commands to ensure that all
DevWorkspace
CRs are removed along with their related Kubernetes objects, such as deployments.oc delete devworkspaces.workspace.devfile.io --all-namespaces --all --wait
$ oc delete devworkspaces.workspace.devfile.io --all-namespaces --all --wait
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete workspaceroutings.controller.devfile.io --all-namespaces --all --wait
$ oc delete workspaceroutings.controller.devfile.io --all-namespaces --all --wait
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete components.controller.devfile.io --all-namespaces --all --wait
$ oc delete components.controller.devfile.io --all-namespaces --all --wait
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 警告If this step is not complete, finalizers make it difficult to fully uninstall the Operator easily.
Run the following commands to remove the CRDs:
oc delete customresourcedefinitions.apiextensions.k8s.io workspaceroutings.controller.devfile.io
$ oc delete customresourcedefinitions.apiextensions.k8s.io workspaceroutings.controller.devfile.io
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete customresourcedefinitions.apiextensions.k8s.io components.controller.devfile.io
$ oc delete customresourcedefinitions.apiextensions.k8s.io components.controller.devfile.io
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete customresourcedefinitions.apiextensions.k8s.io devworkspaces.workspace.devfile.io
$ oc delete customresourcedefinitions.apiextensions.k8s.io devworkspaces.workspace.devfile.io
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Remove the
DevWorkspace-Webhook-Server
deployment:oc delete deployment/devworkspace-webhook-server -n openshift-operators
$ oc delete deployment/devworkspace-webhook-server -n openshift-operators
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 注意When you run this and the following steps, you cannot use the
oc exec
commands to run commands in a container. After you remove the webhooks you will be able to use theoc exec
commands again.Run the following commands to remove any lingering services, secrets, and config maps:
oc delete all --selector app.kubernetes.io/part-of=devworkspace-operator,app.kubernetes.io/name=devworkspace-webhook-server
$ oc delete all --selector app.kubernetes.io/part-of=devworkspace-operator,app.kubernetes.io/name=devworkspace-webhook-server
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete serviceaccounts devworkspace-webhook-server -n openshift-operators
$ oc delete serviceaccounts devworkspace-webhook-server -n openshift-operators
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete configmap devworkspace-controller -n openshift-operators
$ oc delete configmap devworkspace-controller -n openshift-operators
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete clusterrole devworkspace-webhook-server
$ oc delete clusterrole devworkspace-webhook-server
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete clusterrolebinding devworkspace-webhook-server
$ oc delete clusterrolebinding devworkspace-webhook-server
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Run the following commands to remove mutating or validating webhook configurations:
oc delete mutatingwebhookconfigurations controller.devfile.io
$ oc delete mutatingwebhookconfigurations controller.devfile.io
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc delete validatingwebhookconfigurations controller.devfile.io
$ oc delete validatingwebhookconfigurations controller.devfile.io
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
6.3.2. Uninstalling the Operator using the web console 复制链接链接已复制到粘贴板!
Procedure
-
In the Administrator perspective of the web console, navigate to Operators
Installed Operators. - Scroll the filter list or type a keyword into the Filter by name box to find the Web Terminal Operator.
-
Click the Options menu
for the Web Terminal Operator, and then select Uninstall Operator.
- In the Uninstall Operator confirmation dialog box, click Uninstall to remove the Operator, Operator deployments, and pods from the cluster. The Operator stops running and no longer receives updates.