Skip to content

MCO-2032: Avoid MCPs duplication at install time#5518

Merged
openshift-merge-bot[bot] merged 1 commit intoopenshift:mainfrom
pablintino:day-zero-dual-stream
Feb 20, 2026
Merged

MCO-2032: Avoid MCPs duplication at install time#5518
openshift-merge-bot[bot] merged 1 commit intoopenshift:mainfrom
pablintino:day-zero-dual-stream

Conversation

@pablintino
Copy link
Copy Markdown
Contributor

@pablintino pablintino commented Dec 26, 2025

- What I did

Allow the installer to provide MachineConfigPool manifests at bootstrap time. When present, the operator uses them as-is instead of generating its own.
For any managed pool not provided by the installer, the operator generates one with the OSImageStream from the install-config.

On the sync path, if a managed MCP is missing (e.g. deleted by the user), the operator recreates it using the original install-config.

- How to verify it

For all tests, be sure to have a recent openshift-installer, one that contains this change.

Case 1

Automated CI tests for regular installer deployments and hypershift should pass to make sure the default MCPs are still propery generated and consumed.

Case 2

Apply a user given MCP for the worker pool that doesn't use the filename of the MCO builtins

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Add a single MCP that doesn't match the filename we use to see if the MCO properly applies only the user given MCP
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker-mcp.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

Case 3

Apply a user given MCP for the worker pool that uses the same filename the MCO uses

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Add a pool CR to just use rhel-10 in workers
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker.machineconfigpool.yaml 

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

- Description for the changelog

Allow user/installer-provided MachineConfigPool manifests by removing duplicated manifests and ensure the user can reset builtin MCP specs.

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Dec 26, 2025
@openshift-ci-robot
Copy link
Copy Markdown
Contributor

openshift-ci-robot commented Dec 26, 2025

@pablintino: This pull request references MCO-2032 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set.

Details

In response to this:

- What I did

- How to verify it

- Description for the changelog

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 26, 2025
@pablintino pablintino force-pushed the day-zero-dual-stream branch 7 times, most recently from 7180927 to dfbcaff Compare December 31, 2025 09:02
@pablintino pablintino force-pushed the day-zero-dual-stream branch from dfbcaff to 474ec3b Compare January 7, 2026 17:04
@pablintino pablintino force-pushed the day-zero-dual-stream branch 5 times, most recently from e17ccc4 to 9de01c4 Compare February 6, 2026 12:01
@openshift-merge-robot openshift-merge-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Feb 6, 2026
@pablintino pablintino force-pushed the day-zero-dual-stream branch from 9de01c4 to 3840d79 Compare February 6, 2026 12:06
@openshift-merge-robot openshift-merge-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Feb 6, 2026
@pablintino pablintino force-pushed the day-zero-dual-stream branch 2 times, most recently from 28894d3 to a224486 Compare February 6, 2026 12:09
@pablintino pablintino force-pushed the day-zero-dual-stream branch 6 times, most recently from 03f03bb to 0dbc827 Compare February 9, 2026 11:11
@pablintino pablintino changed the title MCO-2032: Read install-config OS Image Streams MCO-2032: Avoid MCPs duplication at install time Feb 12, 2026
@openshift-ci-robot
Copy link
Copy Markdown
Contributor

openshift-ci-robot commented Feb 12, 2026

@pablintino: This pull request references MCO-2032 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set.

Details

In response to this:

- What I did

Allow the installer to provide MachineConfigPool manifests at bootstrap time. When present, the operator uses them as-is instead of generating its own.
For any managed pool not provided by the installer, the operator generates one with the OSImageStream from the install-config.

On the sync path, if a managed MCP is missing (e.g. deleted by the user), the operator recreates it using the original install-config.

- How to verify it

For all tests, be sure to have a recent openshift-installer, one that contains this change.

Case 1

Apply a user given MCP for the worker pool that doesn't use the filename of the MCO builtins

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Add a single MCP that doesn't match the filename we use to see if the MCO properly applies only the user given MCP
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker-mcp.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

Case 2

Apply a user given MCP for the worker pool that uses the same filename the MCO uses

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Add a pool CR to just use rhel-10 in workers
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker.machineconfigpool.yaml

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

- Description for the changelog

Allow user/installer-provided MachineConfigPool manifests by removing duplicated manifests and ensure the user can reset builtin MCP specs.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot
Copy link
Copy Markdown
Contributor

openshift-ci-robot commented Feb 12, 2026

@pablintino: This pull request references MCO-2032 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set.

Details

In response to this:

- What I did

Allow the installer to provide MachineConfigPool manifests at bootstrap time. When present, the operator uses them as-is instead of generating its own.
For any managed pool not provided by the installer, the operator generates one with the OSImageStream from the install-config.

On the sync path, if a managed MCP is missing (e.g. deleted by the user), the operator recreates it using the original install-config.

- How to verify it

For all tests, be sure to have a recent openshift-installer, one that contains this change.

Case 1

Automated CI tests for regular installer deployments and hypershift should pass to make sure the default MCPs are still propery generated and consumed.

Case 2

Apply a user given MCP for the worker pool that doesn't use the filename of the MCO builtins

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Add a single MCP that doesn't match the filename we use to see if the MCO properly applies only the user given MCP
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker-mcp.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

Case 3

Apply a user given MCP for the worker pool that uses the same filename the MCO uses

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Add a pool CR to just use rhel-10 in workers
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker.machineconfigpool.yaml

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

- Description for the changelog

Allow user/installer-provided MachineConfigPool manifests by removing duplicated manifests and ensure the user can reset builtin MCP specs.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@pablintino
Copy link
Copy Markdown
Contributor Author

/jira refresh

@openshift-ci-robot
Copy link
Copy Markdown
Contributor

openshift-ci-robot commented Feb 12, 2026

@pablintino: This pull request references MCO-2032 which is a valid jira issue.

Details

In response to this:

/jira refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot
Copy link
Copy Markdown
Contributor

openshift-ci-robot commented Feb 12, 2026

@pablintino: This pull request references MCO-2032 which is a valid jira issue.

Details

In response to this:

- What I did

Allow the installer to provide MachineConfigPool manifests at bootstrap time. When present, the operator uses them as-is instead of generating its own.
For any managed pool not provided by the installer, the operator generates one with the OSImageStream from the install-config.

On the sync path, if a managed MCP is missing (e.g. deleted by the user), the operator recreates it using the original install-config.

- How to verify it

For all tests, be sure to have a recent openshift-installer, one that contains this change.

Case 1

Automated CI tests for regular installer deployments and hypershift should pass to make sure the default MCPs are still propery generated and consumed.

Case 2

Apply a user given MCP for the worker pool that doesn't use the filename of the MCO builtins

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Add a single MCP that doesn't match the filename we use to see if the MCO properly applies only the user given MCP
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker-mcp.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

Case 3

Apply a user given MCP for the worker pool that uses the same filename the MCO uses

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Add a pool CR to just use rhel-10 in workers
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker.machineconfigpool.yaml 

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

- Description for the changelog

Allow user/installer-provided MachineConfigPool manifests by removing duplicated manifests and ensure the user can reset builtin MCP specs.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

return false
}
for _, generated := range generatedPools {
if reflect.DeepEqual(generated, pool) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question (non-blocking): Why a DeepEqual() here? Is going by name / UUID insufficient to determine uniqueness here?

I'm most likely missing some greater context here 😄

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on how this is used, I think Pablo is using this to check for the exact generated MCP from our manifests, if we find two pools of the same name (i.e. a user provided an MCP override with the same name).

This does account for all metadata, including timestamps, etc. which... may cause unintended false negatives, but I think since this is before any controller/api modification of the MCP objects, in practice that shouldn't happen, so probably fine as is.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on how this is used, I think Pablo is using this to check for the exact generated MCP from our manifests, if we find two pools of the same name (i.e. a user provided an MCP override with the same name).

Correct, and it "works" only because we control the generated data and we know there's nothing dynamic on it. It won't work with MCPs that have been already applied and have, as you said, timestamps, generation, etc.

Copy link
Copy Markdown
Contributor

@yuqi-zhang yuqi-zhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some questions/comments inline

Comment thread pkg/controller/bootstrap/bootstrap.go Outdated

// Group the pools by name
for _, pool := range pools {
if _, ok := groupedPools[pool.Name]; !ok {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this if condition is redundant, and groupedPools[pool.Name] = append(groupedPools[pool.Name], pool) will append properly to a nil slice

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good one, I forgot appending to nil was a safe operation in Go!

return false
}
for _, generated := range generatedPools {
if reflect.DeepEqual(generated, pool) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on how this is used, I think Pablo is using this to check for the exact generated MCP from our manifests, if we find two pools of the same name (i.e. a user provided an MCP override with the same name).

This does account for all metadata, including timestamps, etc. which... may cause unintended false negatives, but I think since this is before any controller/api modification of the MCP objects, in practice that shouldn't happen, so probably fine as is.

var lastPool *mcfgv1.MachineConfigPool
for _, poolObj := range poolObjs {
if manifests.ContainsMachineConfigPool(generatedPools, poolObj) {
// Handle a dev error in case the same pool is
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is interesting. Basically, there's these scenarios you're accounting for here: (G = generated, U = user provided, assuming same pool name)

G, U - this is the easiest, we want U
G, G, U - basically same as above
G, G - we want G
G, U, U - we just take the last match, based on however the slice got sorted (I guess it's maybe based on manifest name?)
U, U - same scenario

And all of them are "valid".

I want to say anything except scenario 1 (G, U) should actually be a failure, because either the user somehow provided conflicting manifests, or we somehow generated duplicates, both of which should be... fails? Would U, U or G, U, U work in the cluster? Or does the manifest parsing reject the duplicate elsewhere?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

G, U, U - we just take the last match, based on however the slice got sorted (I guess it's maybe based on manifest name?)

Yes, the order we had, and still have, in this case is the based on the file name.

I want to say anything except scenario 1 (G, U) should actually be a failure, because either the user somehow provided conflicting manifests, or we somehow generated duplicates, both of which should be... fails? Would U, U or G, U, U work in the cluster? Or does the manifest parsing reject the duplicate elsewhere?

And I would agree, but this exact scenario is how jobs are now configured... https://github.com/openshift/release/pull/73173/changes#diff-4dfd4f4e866cda920dd45858843286a4a93ae1318705fc5b0e5bdc66842afdbfR11 (forget about the manifest_ prefix, the prow job does some mangling with the name and the prefix is removed before the manifest is copied to the installer manifests). I wouldn't like to break the jobs we already have.

Or does the manifest parsing reject the duplicate elsewhere

There's no other filtering. This new function is all we have as filter. The installer doesn't filter either.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, ok, so the installer is doing G, G instead of G, U. Weird, but I guess there's no harm in us filtering for the additional configs for now.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a random followup thought, it this always deterministic? I ask because I wonder if in the case of (default manifest is rhel9, installer provides rhel10) we think both of them to be the generated case, and we take the "last object in the list" but what's guarantee'ing the last object to be then rhel10 overwrite one?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yuqi-zhang So, the default manifest doesn't set the stream at all, we leave it blank and let the render controller pick the default stream when rendering the MCs. So, in theory, that case shouldn't happen. Anyways, the order of the files is deterministic and it's based on the filename.

we think both of them to be the generated case,

That shouldn't be possible, as the deepequals should properly identify the generated one (the rhel-9 one) and the rhel-10 one should, given that, handled always as user provided.

Comment thread pkg/operator/sync.go Outdated
This change is the preparatory work to allow the installer to provide
its own set of MCP, including the managed ones. Without this change
user or installer provided MCPs will collide with the MCO's ones if the
file names are identical.
This change allows users to reset the values of the MCP's spec to zero
as the old merge logic didn't allow it.

Signed-off-by: Pablo Rodriguez Nava <git@amail.pablintino.com>
Copy link
Copy Markdown
Contributor

@yuqi-zhang yuqi-zhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

Looks good after the changes, will let CI validate this doesn't break anything (maybe we should run some RHEL10 jobs if we can invoke them here)

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Feb 13, 2026
@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Feb 13, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: pablintino, yuqi-zhang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [pablintino,yuqi-zhang]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@yuqi-zhang
Copy link
Copy Markdown
Contributor

/label acknowledge-critical-fixes-only

@openshift-ci openshift-ci Bot added the acknowledge-critical-fixes-only Indicates if the issuer of the label is OK with the policy. label Feb 19, 2026
@ptalgulk01
Copy link
Copy Markdown
Contributor

ptalgulk01 commented Feb 19, 2026

Pre-merge verification steps:

Pre-requisites


$ ./openshift-install create manifests
? SSH Public Key 
? Platform aws
INFO Credentials loaded from the AWS config using "SharedConfigCredentials: 
? Region
INFO Credentials loaded from the "default" profile in file 
? Base Domain 
? Cluster Name pablo-19c
? Pull Secret [? for help] 
defaulting to "IPv4" 
WARNING Release Image Architecture not detected. Release Image Architecture is unknown 
INFO Successfully populated MCS CA cert information: root-ca 2036-02-17T09:17:43Z 2026-02-19T09:17:43Z 
INFO Successfully populated MCS TLS cert information: root-ca 2036-02-17T09:17:43Z 2026-02-19T09:17:43Z 
INFO Adding clusters...                           
INFO Manifests created in: cluster-api, manifests and openshift 
Templates
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfigPool
metadata:
  name: master
  labels:
    "operator.machineconfiguration.openshift.io/required-for-upgrade": ""
    "machineconfiguration.openshift.io/mco-built-in": ""
    "pools.operator.machineconfiguration.openshift.io/master": ""
spec:
  machineConfigSelector:
    matchLabels:
      "machineconfiguration.openshift.io/role": "master"
  nodeSelector:
    matchLabels:
      node-role.kubernetes.io/master: ""
  osImageStream:
    name: rhel-10

apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfigPool
metadata:
name: worker
labels:
"machineconfiguration.openshift.io/mco-built-in": ""
"pools.operator.machineconfiguration.openshift.io/worker": ""
spec:
machineConfigSelector:
matchLabels:
"machineconfiguration.openshift.io/role": "worker"
nodeSelector:
matchLabels:
node-role.kubernetes.io/worker: ""
osImageStream:
name: rhel-10

Case1: added the below files in openshift/ folder of manifests in mcp-<name>.yaml file
Case2: added the below files in openshift/ folder of manifests in <name>.machineconfigpool.yaml .yaml file
For both cases the cluster was deployed without any issue

  • After cluster installation complete check the mcp and nodes are showing on rhel-10
$ oc debug node/ip-10-0-73-37.us-west-1.compute.internal -- chroot /host rpm-ostree status
Starting pod/ip-10-0-73-37us-west-1computeinternal-debug-h7kwp ...
To use host binaries, run `chroot /host`
State: idle
Deployments:
* ostree-unverified-registry:registry.build07.ci.openshift.org/ci-ln-tw81zyk/stable@sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                   Digest: sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                  Version: 10.1.20260126-0 (2026-01-27T06:43:47Z)

Removing debug pod ...

$ oc debug node/ip-10-0-34-153.us-west-1.compute.internal -- chroot /host rpm-ostree status
Starting pod/ip-10-0-34-153us-west-1computeinternal-debug-ptvdm ...
To use host binaries, run `chroot /host`
State: idle
Deployments:
* ostree-unverified-registry:registry.build07.ci.openshift.org/ci-ln-tw81zyk/stable@sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                   Digest: sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                  Version: 10.1.20260126-0 (2026-01-27T06:43:47Z)

Removing debug pod ...
$ oc get mcp worker -ojsonpath='{.status.osImageStream.name}'
rhel-10

$ oc get mcp master -ojsonpath='{.status.osImageStream.name}'
rhel-10

/label qe-approved
/verified by @ptalgulk01

@openshift-ci openshift-ci Bot added the qe-approved Signifies that QE has signed off on this PR label Feb 19, 2026
@openshift-ci-robot
Copy link
Copy Markdown
Contributor

openshift-ci-robot commented Feb 19, 2026

@pablintino: This pull request references MCO-2032 which is a valid jira issue.

Details

In response to this:

- What I did

Allow the installer to provide MachineConfigPool manifests at bootstrap time. When present, the operator uses them as-is instead of generating its own.
For any managed pool not provided by the installer, the operator generates one with the OSImageStream from the install-config.

On the sync path, if a managed MCP is missing (e.g. deleted by the user), the operator recreates it using the original install-config.

- How to verify it

For all tests, be sure to have a recent openshift-installer, one that contains this change.

Case 1

Automated CI tests for regular installer deployments and hypershift should pass to make sure the default MCPs are still propery generated and consumed.

Case 2

Apply a user given MCP for the worker pool that doesn't use the filename of the MCO builtins

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Add a single MCP that doesn't match the filename we use to see if the MCO properly applies only the user given MCP
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker-mcp.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

Case 3

Apply a user given MCP for the worker pool that uses the same filename the MCO uses

export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=<build-with-this-change>
mkdir installer-dir
# Call the installer to generate the install-config. Follow the instructions
./openshift-install --dir installer-dir create manifests

# Add a pool CR to just use rhel-10 in workers
curl -s https://raw.githubusercontent.com/openshift/machine-config-operator/refs/heads/main/manifests/worker.machineconfigpool.yaml | yq '.spec.osImageStream.name = "rhel-10"' > installer-dir/openshift/worker.machineconfigpool.yaml 

# Enable TechPreview
yq -i '.spec.featureSet = "TechPreviewNoUpgrade"' installer-dir/openshift/99_feature-gate.yaml

# Run the cluster installation
./openshift-install --dir installer-dir create cluster

- Description for the changelog

Allow user/installer-provided MachineConfigPool manifests by removing duplicated manifests and ensure the user can reset builtin MCP specs.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot openshift-ci-robot added the verified Signifies that the PR passed pre-merge verification criteria label Feb 19, 2026
@openshift-ci-robot
Copy link
Copy Markdown
Contributor

@ptalgulk01: This PR has been marked as verified by @ptalgulk01.

Details

In response to this:

Pre-merge verification steps:

Pre-requisites


$ ./openshift-install create manifests
? SSH Public Key 
? Platform aws
INFO Credentials loaded from the AWS config using "SharedConfigCredentials: 
? Region
INFO Credentials loaded from the "default" profile in file 
? Base Domain 
? Cluster Name pablo-19c
? Pull Secret [? for help] 
defaulting to "IPv4" 
WARNING Release Image Architecture not detected. Release Image Architecture is unknown 
INFO Successfully populated MCS CA cert information: root-ca 2036-02-17T09:17:43Z 2026-02-19T09:17:43Z 
INFO Successfully populated MCS TLS cert information: root-ca 2036-02-17T09:17:43Z 2026-02-19T09:17:43Z 
INFO Adding clusters...                           
INFO Manifests created in: cluster-api, manifests and openshift 
Templates
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfigPool
metadata:
 name: master
 labels:
   "operator.machineconfiguration.openshift.io/required-for-upgrade": ""
   "machineconfiguration.openshift.io/mco-built-in": ""
   "pools.operator.machineconfiguration.openshift.io/master": ""
spec:
 machineConfigSelector:
   matchLabels:
     "machineconfiguration.openshift.io/role": "master"
 nodeSelector:
   matchLabels:
     node-role.kubernetes.io/master: ""
 osImageStream:
   name: rhel-10

apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfigPool
metadata:
name: worker
labels:
"machineconfiguration.openshift.io/mco-built-in": ""
"pools.operator.machineconfiguration.openshift.io/worker": ""
spec:
machineConfigSelector:
matchLabels:
"machineconfiguration.openshift.io/role": "worker"
nodeSelector:
matchLabels:
node-role.kubernetes.io/worker: ""
osImageStream:
name: rhel-10

Case1: added the below files in openshift/ folder of manifests in mcp-<name>.yaml file
Case2: added the below files in openshift/ folder of manifests in <name>.machineconfigpool.yaml .yaml file

  • After cluster installation complete check the mcp and nodes are showing on rhel-10
$ oc debug node/ip-10-0-73-37.us-west-1.compute.internal -- chroot /host rpm-ostree status
Starting pod/ip-10-0-73-37us-west-1computeinternal-debug-h7kwp ...
To use host binaries, run `chroot /host`
State: idle
Deployments:
* ostree-unverified-registry:registry.build07.ci.openshift.org/ci-ln-tw81zyk/stable@sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                  Digest: sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                 Version: 10.1.20260126-0 (2026-01-27T06:43:47Z)

Removing debug pod ...

$ oc debug node/ip-10-0-34-153.us-west-1.compute.internal -- chroot /host rpm-ostree status
Starting pod/ip-10-0-34-153us-west-1computeinternal-debug-ptvdm ...
To use host binaries, run `chroot /host`
State: idle
Deployments:
* ostree-unverified-registry:registry.build07.ci.openshift.org/ci-ln-tw81zyk/stable@sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                  Digest: sha256:4a1798a3b92a794a69d56eaf78c1521a1c4d2e52fd05057072780ec19ccabd45
                 Version: 10.1.20260126-0 (2026-01-27T06:43:47Z)

Removing debug pod ...
$ oc get mcp worker -ojsonpath='{.status.osImageStream.name}'
rhel-10

$ oc get mcp master -ojsonpath='{.status.osImageStream.name}'
rhel-10

/label qe-approved
/verified by @ptalgulk01

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@pablintino
Copy link
Copy Markdown
Contributor Author

/test unit

@pablintino
Copy link
Copy Markdown
Contributor Author

/test e2e-hypershift

@pablintino
Copy link
Copy Markdown
Contributor Author

/retest-required

1 similar comment
@pablintino
Copy link
Copy Markdown
Contributor Author

/retest-required

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Feb 20, 2026

@pablintino: all tests passed!

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@openshift-merge-bot openshift-merge-bot Bot merged commit e8fd02f into openshift:main Feb 20, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

acknowledge-critical-fixes-only Indicates if the issuer of the label is OK with the policy. approved Indicates a PR has been approved by an approver from all required OWNERS files. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged. qe-approved Signifies that QE has signed off on this PR verified Signifies that the PR passed pre-merge verification criteria

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants