Chapter 5. Managing non-versioned and versioned cluster tasks
As a cluster administrator, installing the Red Hat OpenShift Pipelines Operator creates variants of each default cluster task known as versioned cluster tasks (VCT) and non-versioned cluster tasks (NVCT). For example, installing the Red Hat OpenShift Pipelines Operator v1.7 creates a buildah-1-7-0
VCT and a buildah
NVCT.
Both NVCT and VCT have the same metadata, behavior, and specifications, including params
, workspaces
, and steps
. However, they behave differently when you disable them or upgrade the Operator.
In Red Hat OpenShift Pipelines 1.10, cluster task functionality is deprecated and is planned to be removed in a future release.
5.1. Differences between non-versioned and versioned cluster tasks Copy linkLink copied to clipboard!
Non-versioned and versioned cluster tasks have different naming conventions. And, the Red Hat OpenShift Pipelines Operator upgrades them differently.
Non-versioned cluster task | Versioned cluster task | |
---|---|---|
Nomenclature |
The NVCT only contains the name of the cluster task. For example, the name of the NVCT of Buildah installed with Operator v1.7 is |
The VCT contains the name of the cluster task, followed by the version as a suffix. For example, the name of the VCT of Buildah installed with Operator v1.7 is |
Upgrade | When you upgrade the Operator, it updates the non-versioned cluster task with the latest changes. The name of the NVCT remains unchanged. |
Upgrading the Operator installs the latest version of the VCT and retains the earlier version. The latest version of a VCT corresponds to the upgraded Operator. For example, installing Operator 1.7 installs |
5.2. Advantages and disadvantages of non-versioned and versioned cluster tasks Copy linkLink copied to clipboard!
Before adopting non-versioned or versioned cluster tasks as a standard in production environments, cluster administrators might consider their advantages and disadvantages.
Cluster task | Advantages | Disadvantages |
---|---|---|
Non-versioned cluster task (NVCT) |
| If you deploy pipelines that use NVCT, they might break after an Operator upgrade if the automatically upgraded cluster tasks are not backward-compatible. |
Versioned cluster task (VCT) |
|
|
5.3. Disabling non-versioned and versioned cluster tasks Copy linkLink copied to clipboard!
As a cluster administrator, you can disable cluster tasks that the OpenShift Pipelines Operator installed.
Procedure
To delete all non-versioned cluster tasks and latest versioned cluster tasks, edit the
TektonConfig
custom resource definition (CRD) and set theclusterTasks
parameter inspec.addon.params
tofalse
.Example
TektonConfig
CRCopy to Clipboard Copied! Toggle word wrap Toggle overflow When you disable cluster tasks, the Operator removes all the non-versioned cluster tasks and only the latest version of the versioned cluster tasks from the cluster.
NoteRe-enabling cluster tasks installs the non-versioned cluster tasks.
Optional: To delete earlier versions of the versioned cluster tasks, use any one of the following methods:
To delete individual earlier versioned cluster tasks, use the
oc delete clustertask
command followed by the versioned cluster task name. For example:oc delete clustertask buildah-1-6-0
$ oc delete clustertask buildah-1-6-0
Copy to Clipboard Copied! Toggle word wrap Toggle overflow To delete all versioned cluster tasks created by an old version of the Operator, you can delete the corresponding installer set. For example:
oc delete tektoninstallerset versioned-clustertask-1-6-k98as
$ oc delete tektoninstallerset versioned-clustertask-1-6-k98as
Copy to Clipboard Copied! Toggle word wrap Toggle overflow ImportantIf you delete an old versioned cluster task, you cannot restore it. You can only restore versioned and non-versioned cluster tasks that the current version of the Operator has created.