Installing Red Hat build of Kueue
You can install Red Hat build of Kueue by using the Red Hat Build of Kueue Operator in OperatorHub.
Compatible environments
Your cluster must meet specific architecture and platform requirements before you can install Red Hat build of Kueue.
Supported architectures
Red Hat build of Kueue version 1.1 and later is supported on the following architectures:
- ARM64
- 64-bit x86
- ppc64le (IBM Power(R))
- s390x (IBM Z(R))
Supported platforms
Red Hat build of Kueue version 1.1 and later is supported on the following platforms:
- OpenShift Container Platform
- Hosted control planes for OpenShift Container Platform
Currently, Red Hat build of Kueue is not supported on Red Hat build of MicroShift (MicroShift).
Installing the Red Hat Build of Kueue Operator
You can install the Red Hat Build of Kueue Operator on a OpenShift Container Platform cluster by using the OperatorHub in the web console.
Prerequisites
- You have administrator permissions on a OpenShift Container Platform cluster.
- You have access to the OpenShift Container Platform web console.
- You have installed and configured the cert-manager Operator for Red Hat OpenShift for your cluster.
Procedure
- In the OpenShift Container Platform web console, click Operators → OperatorHub.
- Choose Red Hat Build of Kueue Operator from the list of available Operators, and click Install.
- Select Enable Operator recommended cluster monitoring on this Namespace.
This option sets the
openshift.io/cluster-monitoring: "true"label in the Namespace object. You must select this option to ensure that cluster monitoring scrapes theopenshift-kueue-operatornamespace. - Click Install.Note
Alternatively, if you are creating the
Namespaceobject by using YAML, ensure that you include theopenshift.io/cluster-monitoring: "true"label:yamlapiVersion: v1 kind: Namespace metadata: labels: openshift.io/cluster-monitoring: "true" name: openshift-kueue-operator
Verification
- Go to Operators → Installed Operators and confirm that the Red Hat Build of Kueue Operator is listed with Status as Succeeded.
Upgrading Red Hat build of Kueue
If you have previously installed Red Hat build of Kueue, you must manually upgrade your deployment to the latest version to use the latest bug fixes and feature enhancements.
Prerequisites
- You have installed a previous version of Red Hat build of Kueue.
- You are logged in to the OpenShift Container Platform web console with cluster administrator permissions.
Procedure
- In the OpenShift Container Platform web console, click Operators → Installed Operators, then select Red Hat build of Kueue from the list.
- From the Actions drop-down menu, select Uninstall Operator.
- The Uninstall Operator? dialog box opens. Click Uninstall.Important
Selecting the Delete all operand instances for this operator checkbox before clicking Uninstall deletes all existing resources from the cluster, including:
- The
KueueCR - Any cluster queues, local queues, or resource flavors that you have created
Leave this box unchecked when upgrading your cluster to retain your created resources.
- The
- In the OpenShift Container Platform web console, click Operators → OperatorHub.
- Choose Red Hat Build of Kueue Operator from the list of available Operators, and click Install.
Verification
- Go to Operators → Installed Operators.
- Confirm that the Red Hat Build of Kueue Operator is listed with Status as Succeeded.
- Confirm that the version shown under the Operator name in the list is the latest version.
Creating a Kueue custom resource
After you have installed the Red Hat Build of Kueue Operator, you must create a Kueue custom resource (CR) to configure your installation.
Prerequisites
Ensure that you have completed the following prerequisites:
- The Red Hat build of Kueue Operator is installed on your cluster.
- You have cluster administrator permissions and the
kueue-batch-admin-rolerole. - You have access to the OpenShift Container Platform web console.
Procedure
- In the OpenShift Container Platform web console, click Operators → Installed Operators.
- In the Provided APIs table column, click Kueue. This takes you to the Kueue tab of the Operator details page.
- Click Create Kueue. This takes you to the Create Kueue YAML view.
- Enter the details for your
KueueCR.Example Kueue CRapiVersion: kueue.openshift.io/v1 kind: Kueue metadata: labels: app.kubernetes.io/name: kueue-operator app.kubernetes.io/managed-by: kustomize name: cluster namespace: openshift-kueue-operator spec: managementState: Managed config: integrations: frameworks: - BatchJob preemption: preemptionPolicy: Classical # ...where:
metadata.nameSpecifies the name of the
KueueCR. The value must becluster.spec.config.integrations.frameworksSpecifies the workload types to configure for Red Hat build of Kueue. The default configuration is
BatchJob. Additional types arePod,Deployment, andStatefulSet.spec.config.preemption.preemptionPolicySpecifies the preemption policy for Red Hat build of Kueue. Set the value to
FairSharingto configure fair sharing. The default value isClassical. This value is optional.
- Click Create.
Verification
- After you create the
KueueCR, the web console brings you to the Operator details page, where you can see the CR in the list of Kueues. - Optional: If you have the OpenShift CLI (
oc) installed, you can run the following command and observe the output to confirm that yourKueueCR has been created successfully:terminal$ oc get kueueExample outputNAME AGE cluster 4m
Labeling namespaces to allow Red Hat build of Kueue to manage jobs
You must add the kueue.openshift.io/managed=true label to each namespace where you want Red Hat build of Kueue to manage jobs, because the Operator only enforces policies on labeled namespaces.
Prerequisites
- You have cluster administrator permissions.
- The Red Hat build of Kueue Operator is installed on your cluster, and you have created a
Kueuecustom resource (CR). - You have installed the OpenShift CLI (
oc).
Procedure
- Add the
kueue.openshift.io/managed=truelabel to a namespace by running the following command:terminal$ oc label namespace <namespace> kueue.openshift.io/managed=trueWhen you add this label, you instruct the Red Hat build of Kueue Operator that the namespace is managed by its webhook admission controllers. As a result, any Red Hat build of Kueue resources within that namespace are properly validated and mutated.