-
Feature Request
-
Resolution: Unresolved
-
Normal
-
None
-
openshift-4.21
-
None
-
Product / Portfolio Work
-
None
-
False
-
-
None
-
None
-
None
-
-
None
-
None
-
None
-
None
-
None
1. Proposed title of this feature request
Implement Node Affinity support for KubeVirt NodePools in Hosted Control Planes (HCP)
2. What is the nature and description of the request?
The request is to extend the NodePool CRD (specifically np.spec.platform.kubevirt) to support the nodeAffinity field.
Currently, the KubeVirt platform provider in HyperShift only supports nodeSelector, which is limited to simple key-value pair matching. By introducing nodeAffinity, users will be able to leverage:
Required Scheduling: Strict rules using logical operators (In, NotIn, Exists, DoesNotExist etc ).
Preferred Scheduling: "Soft" rules that allow the scheduler to attempt to place VMs on specific nodes but fall back to others if the preferred nodes are unavailable.
Complex Expressions: Matching nodes based on multiple labels or dynamic environmental factors that nodeSelector cannot handle.
3. Why does the customer need this? (List the business requirements here)
Workload Isolation & Compliance: Customers running regulated workloads need to ensure that the VMs (which serve as the hosted cluster nodes) land on specific, audited physical hardware or dedicated "infra" nodes.
Hardware-Specific Performance: For workloads requiring high-performance networking or specific CPU instructions (e.g., AVX-512), nodeAffinity allows the operator to prefer nodes with those capabilities without causing a scheduling failure if those nodes are at capacity.
High Availability & Failure Domains: Customers need to distribute NodePool VMs across specific Availability Zones or Racks within the management cluster to ensure that a single rack/zone failure doesn't take down the entire data plane of a hosted cluster.
Resource Optimization: Large-scale deployments require "Preferred" affinity to pack VMs onto underutilized nodes first, optimizing the footprint of the management cluster.
4. List any affected packages or components.
HCP KubeVirt