[multiple] Add per-node BMH label for deterministic node assignment#3890
Merged
openshift-merge-bot[bot] merged 1 commit intoopenstack-k8s-operators:mainfrom Apr 28, 2026
Merged
Conversation
When `preProvisioned: false`, the OSDPO's `OpenStackBaremetalSet`
assigns BareMetalHost CRs to NodeSet nodes non-deterministically
(OSPRH-10282). This causes hostname shuffling: a node provisioned
from BMH `compute-0` may receive the hostname of `compute-2`,
breaking services that depend on hostname correctness (e.g. Ceph
`orch apply` fails with "hostname does not match expected hostname").
Fix by establishing a 1-to-1 mapping between BMH CRs and NodeSet
nodes using per-node `bmhLabelSelector`:
- `deploy_bmh` template: add a `nodeName` label to every BMH CR,
set to the node's name (e.g. `nodeName: compute-0`).
- `ci_gen_kustomize_values` common edpm-nodeset-values template:
when `cifmw_edpm_deploy_pre_provisioned` is `false`, emit a
per-node `bmhLabelSelector: {nodeName: <instance>}` so each
NodeSet node selects its specific BMH by label.
Pre-provisioned deployments are unaffected (the `bmhLabelSelector`
is only emitted when `cifmw_edpm_deploy_pre_provisioned` is false,
which defaults to true).
Depends-On: openstack-k8s-operators#3884
Depends-On: openstack-k8s-operators/architecture#746
Related-to: ANVIL-108
Co-authored-by: Claude <noreply@anthropic.com>
Signed-off-by: Roberto Alfieri <ralfieri@redhat.com>
evallesp
approved these changes
Apr 27, 2026
Contributor
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: evallesp The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
77c5ed6
into
openstack-k8s-operators:main
12 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When
preProvisioned: false, the OSDPO'sOpenStackBaremetalSetassigns BareMetalHost CRs to NodeSet nodes non-deterministically (OSPRH-10282). This causes hostname shuffling: a node provisioned from BMHcompute-0may receive the hostname ofcompute-2, breaking services that depend on hostname correctness (e.g. Cephorch applyfails with "hostname does not match expected hostname").Fix by establishing a 1-to-1 mapping between BMH CRs and NodeSet nodes using per-node
bmhLabelSelector:deploy_bmhtemplate: add anodeNamelabel to every BMH CR,set to the node's name (e.g.
nodeName: compute-0).ci_gen_kustomize_valuescommon edpm-nodeset-values template: whencifmw_edpm_deploy_pre_provisionedisfalse, emit a per-nodebmhLabelSelector: {nodeName: <instance>}so each NodeSet node selects its specific BMH by label.Pre-provisioned deployments are unaffected (the
bmhLabelSelectoris only emitted whencifmw_edpm_deploy_pre_provisionedis false, which defaults to true).Depends-On: #3884
Depends-On: openstack-k8s-operators/architecture#746
Related-to: ANVIL-108