Skip to content

MCO-2200: refactored node-joiner to use embedded rhcos data#10537

Open
andfasano wants to merge 3 commits intoopenshift:mainfrom
andfasano:nodejoiner-use-embedded-rhcos-data
Open

MCO-2200: refactored node-joiner to use embedded rhcos data#10537
andfasano wants to merge 3 commits intoopenshift:mainfrom
andfasano:nodejoiner-use-embedded-rhcos-data

Conversation

@andfasano
Copy link
Copy Markdown
Contributor

@andfasano andfasano commented May 7, 2026

(Followup from the discussions in #10534)

This patch simplifies the node-joiner code, so that now it retrieves the bootimages data from the embedded streams (instead of fetching them from the coreos-bootimages ConfigMap in the target cluster).
As previously discussed, the advantages of this new approach are:

  • Simpler code (no difference between the various ABI workflows for retrieving the data)
  • Will make it simpler adopt the osImageStream adoption for selecting the current steam

Summary by CodeRabbit

  • Refactor

    • Consolidated OS/ISO artifact retrieval into a single metal-artifact lookup and simplified base-ISO fetching across image generation paths.
    • Removed per-cluster OS image inspection and related fields from the join workflow.
  • Tests

    • Simplified unit tests by removing reliance on embedded stream metadata and related fixtures.
  • Documentation

    • Added node-joiner command guidance and an acceptance scenario for embedded RHCOS metadata.

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

openshift-ci-robot commented May 7, 2026

@andfasano: This pull request references MCO-2200 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 "5.0.0" version, but no target version was set.

Details

In response to this:

(Followup from the discussions in #10534)

This patch simplifies the node-joiner code, so that now it retrieves the bootimages data from the embedded streams (instead of fetching them from the coreos-bootimages ConfigMap in the target cluster).
As previously discussed, the advantages of this new approach are:

  • Simpler code (no difference between the various ABI workflows for retrieving the data)
  • Will make it simpler adopt the osImageStream adoption for selecting the current steam

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.

@andfasano
Copy link
Copy Markdown
Contributor Author

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 7, 2026

Walkthrough

Base RHCOS artifact fetching was centralized: injected CoreOS stream fetchers were removed in favor of a package-level metal-artifact getter. Call sites and signatures across rhcos, agent image, imagebased, and joiner code were simplified, and ClusterInfo no longer stores OS image metadata.

Changes

CoreOS Artifact Fetch Consolidation

Layer / File(s) Summary
Data Shape / API
pkg/asset/rhcos/releaseextract.go, pkg/asset/rhcos/iso.go
ReleasePayload.GetBaseIso and related helpers drop the CoreOSBuildFetcher parameter; new package-level GetMetalArtifact(ctx, archName) added. NewBaseISOFetcher no longer accepts a stream getter.
Core Implementation
pkg/asset/rhcos/iso.go, pkg/asset/rhcos/releaseextract.go
Installer/metal-artifact lookups now call GetMetalArtifact / rhcos.FetchCoreOSBuild internally (30s timeout). Cache verification and installer-hash retrieval updated to use internal fetch.
Agent Image / Ignition
pkg/asset/agent/image/baseiso.go, pkg/asset/agent/image/agentimage.go, pkg/asset/agent/image/ignition.go, pkg/asset/agent/image/unconfigured_ignition.go
BaseIso.getRootFSURL and callers updated to (ctx, archName); getOSImagesInfo simplified and no longer accepts a custom stream getter. customStreamGetter removed.
Image-based Base ISO
pkg/asset/imagebased/image/baseiso.go, pkg/asset/imagebased/image/baseiso_test.go
BaseIso.Generate and downloadBaseIso now accept ctx and call assetrhcos.GetMetalArtifact(ctx, archName); tests simplified to drop stream-metadata mocking.
Joiner / ClusterInfo
pkg/asset/agent/joiner/clusterinfo.go, pkg/asset/agent/joiner/clusterinfo_test.go
ClusterInfo fields OSImage and OSImageLocation and retrieveOsImage removed; imports and tests updated to drop stream/OSImage fixtures and assertions.
Tests & Docs
pkg/asset/rhcos/iso_test.go, pkg/asset/rhcos/*, pkg/nodejoiner/.claude/skills/*
Mocks and tests adjusted for the simplified GetBaseIso signature; node-joiner skill and acceptance docs added regarding embedded CoreOS bootimages metadata.

Sequence Diagram(s)

sequenceDiagram
    participant Agent as AgentImage / Ignition
    participant Base as BaseIso / ReleasePayload
    participant RHCOS as rhcos.GetMetalArtifact
    participant Cache as Cache/Storage

    Agent->>Base: Request base ISO or rootfs URL (ctx, arch)
    Base->>RHCOS: GetMetalArtifact(ctx, arch)
    RHCOS-->>Base: Return metal artifact (iso, installer metadata)
    Base->>Cache: Check/verify or download ISO using artifact info
    Cache-->>Base: Return cached or downloaded ISO + hash
    Base-->>Agent: Return ISO path / rootfs URL
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

🚥 Pre-merge checks | ✅ 11 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 15.38% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (11 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Stable And Deterministic Test Names ✅ Passed This PR does not contain any Ginkgo tests. All modified test files use standard Go testing with t.Run(). Since the custom check applies only to Ginkgo tests, it is not applicable.
Test Structure And Quality ✅ Passed This PR modifies standard Go table-driven tests, not Ginkgo tests. Check does not apply.
Microshift Test Compatibility ✅ Passed No new Ginkgo e2e tests were added in this PR. Changes consist of implementation code refactoring, unit test updates (standard Go testing.T), and documentation. Custom check is not applicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed No Ginkgo e2e tests added. All test file changes are standard Go unit tests. Custom check does not apply.
Topology-Aware Scheduling Compatibility ✅ Passed Installer-time asset generation code only. No deployment manifests, operators, or pod scheduling constraints. No affinity rules, topology constraints, or nodeSelectors affecting cluster topologies.
Ote Binary Stdout Contract ✅ Passed All modified files are library code, not OTE binary entry points. No stdout writes detected: no fmt.Print variants, no os.Stdout, no problematic init() functions, no improper klog configuration.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed No new Ginkgo e2e tests added. PR modifies 9 implementation .go files, 3 unit test files (using standard testing package), and 2 documentation .md files. Check is not applicable to this PR.
Title check ✅ Passed The title accurately summarizes the main change: refactoring node-joiner to use embedded RHCOS data instead of fetching from ConfigMap.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented May 7, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign pawanpinjarkar for approval. For more information see the Code Review Process.

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

Details Needs approval from an approver in each of these files:

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

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
pkg/asset/rhcos/releaseextract.go (1)

269-319: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Cache validation can incorrectly trust default-stream metadata over the actual release payload.

On Line 273 you fetch hash data from rhcos.DefaultOSImageStream, and on Line 317 you return early when that hash matches. That short-circuits the release-payload SHA check (Lines 330-344), so a cached ISO can be accepted even if it does not match the specific image being installed.

Suggested fix
-	// Check if the hash of cached file matches hash in rhcos.json
-	found, rhcosSha := r.getHashFromInstaller(architecture)
-	if found && matchingHash(fileSha, rhcosSha) {
-		logrus.Debug("Found matching hash in installer metadata")
-		return true, nil
-	}
-
-	// If no match, get the file containing the coreos sha256 and compare that
+	// First, compare against release payload SHA (authoritative for `image`)
 	tempDir, err := os.MkdirTemp("", "cache")
 	if err != nil {
 		return false, err
@@
 	if matchingHash(fileSha, string(payloadSha)) {
 		logrus.Debugf("Found matching hash in %s", shaFilename)
 		return true, nil
 	}
+
+	// Fallback to installer metadata only when payload SHA cannot confirm a match.
+	found, rhcosSha := r.getHashFromInstaller(architecture)
+	if found && matchingHash(fileSha, rhcosSha) {
+		logrus.Debug("Found matching hash in installer metadata")
+		return true, nil
+	}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pkg/asset/rhcos/releaseextract.go` around lines 269 - 319, verifyCacheFile
currently trusts the default stream hash from getHashFromInstaller(architecture)
and returns early when it matches, which can bypass validating the SHA from the
specific release payload referenced by image; change the logic so
verifyCacheFile first extracts the RHCOS SHA from the release payload associated
with the given image (instead of or before calling getHashFromInstaller),
compare fileSha against that release-specific SHA, and only if no
release-payload SHA is available fall back to using
getHashFromInstaller(architecture); update getHashFromInstaller or add a new
helper to clearly indicate it returns a default-stream/fallback SHA so the code
in verifyCacheFile checks payload SHA first, then fallback SHA.
🧹 Nitpick comments (1)
pkg/asset/agent/image/baseiso.go (1)

53-70: 💤 Low value

Remove unused ClusterInfo dependency.

The clusterInfo variable is fetched at line 70 but never used in the Generate method. Remove it from the Dependencies() declaration at line 57 and the dependencies.Get() call at line 70.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pkg/asset/agent/image/baseiso.go` around lines 53 - 70, Remove the unused
ClusterInfo dependency from BaseIso: in the Dependencies() method of BaseIso,
delete the &joiner.ClusterInfo{} entry, and in the Generate(ctx context.Context,
dependencies asset.Parents) method remove the clusterInfo variable and its
inclusion from the dependencies.Get(...) call so you only fetch the actually
used assets (manifests.AgentManifests, mirror.RegistriesConf,
workflow.AgentWorkflow / agent.OptionalInstallConfig as applicable).
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@pkg/nodejoiner/.claude/skills/nodejoiner-command/SKILL.md`:
- Around line 8-9: Update the documentation text in SKILL.md for the nodejoiner
description: fix the typos "builind" → "building", "come" → "code", and
"sligtly" → "slightly", and also correct "is a internal command" to "is an
internal command" so the sentence reads clearly; the sentence references the
nodejoiner used by oc adm nodeimage and the workflow.AgentWorkflowTypeAddNodes
enum — make these wording fixes in that paragraph accordingly.

---

Outside diff comments:
In `@pkg/asset/rhcos/releaseextract.go`:
- Around line 269-319: verifyCacheFile currently trusts the default stream hash
from getHashFromInstaller(architecture) and returns early when it matches, which
can bypass validating the SHA from the specific release payload referenced by
image; change the logic so verifyCacheFile first extracts the RHCOS SHA from the
release payload associated with the given image (instead of or before calling
getHashFromInstaller), compare fileSha against that release-specific SHA, and
only if no release-payload SHA is available fall back to using
getHashFromInstaller(architecture); update getHashFromInstaller or add a new
helper to clearly indicate it returns a default-stream/fallback SHA so the code
in verifyCacheFile checks payload SHA first, then fallback SHA.

---

Nitpick comments:
In `@pkg/asset/agent/image/baseiso.go`:
- Around line 53-70: Remove the unused ClusterInfo dependency from BaseIso: in
the Dependencies() method of BaseIso, delete the &joiner.ClusterInfo{} entry,
and in the Generate(ctx context.Context, dependencies asset.Parents) method
remove the clusterInfo variable and its inclusion from the dependencies.Get(...)
call so you only fetch the actually used assets (manifests.AgentManifests,
mirror.RegistriesConf, workflow.AgentWorkflow / agent.OptionalInstallConfig as
applicable).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 8e9c903b-e447-4a5c-b2a8-91faad36afd7

📥 Commits

Reviewing files that changed from the base of the PR and between c782a19 and 43933d0.

📒 Files selected for processing (11)
  • pkg/asset/agent/image/agentimage.go
  • pkg/asset/agent/image/baseiso.go
  • pkg/asset/agent/image/ignition.go
  • pkg/asset/agent/image/unconfigured_ignition.go
  • pkg/asset/agent/joiner/clusterinfo.go
  • pkg/asset/agent/joiner/clusterinfo_test.go
  • pkg/asset/rhcos/iso.go
  • pkg/asset/rhcos/iso_test.go
  • pkg/asset/rhcos/releaseextract.go
  • pkg/nodejoiner/.claude/skills/nodejoiner-command/SKILL.md
  • pkg/nodejoiner/.claude/skills/nodejoiner-command/acceptance/coreos-bootimages-data.md
💤 Files with no reviewable changes (1)
  • pkg/asset/agent/joiner/clusterinfo.go

Comment thread pkg/nodejoiner/.claude/skills/nodejoiner-command/SKILL.md Outdated
currently it contains just the additional file for removing the bootstrap images management from ClusterInfo
@andfasano andfasano force-pushed the nodejoiner-use-embedded-rhcos-data branch from 1f8983c to df11856 Compare May 7, 2026 14:12
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
pkg/asset/imagebased/image/baseiso.go (1)

88-94: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Potential nil pointer dereference on format.Disk.

The code checks if the "iso" format exists in the map but does not verify that format.Disk is non-nil before accessing its fields. In stream-metadata-go's ImageFormat, the Disk field is a pointer and could be nil if only other artifact types (e.g., Kernel, Initramfs) are set for that format.

🛡️ Proposed fix to add nil check
 	format, ok := metal.Formats["iso"]
 	if !ok {
 		return "", fmt.Errorf("no ISO found to download for %s", archName)
 	}
+	if format.Disk == nil {
+		return "", fmt.Errorf("no ISO disk artifact found for %s", archName)
+	}

 	url := format.Disk.Location
 	sha := format.Disk.Sha256
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pkg/asset/imagebased/image/baseiso.go` around lines 88 - 94, The code uses
metal.Formats["iso"] without verifying format.Disk is non-nil, risking a nil
pointer when accessing format.Disk.Location and format.Disk.Sha256; update the
logic after retrieving format (from metal.Formats["iso"]) to check that
format.Disk != nil and return a clear error (including archName) if it's nil,
before using format.Disk to set url and sha.
🧹 Nitpick comments (2)
pkg/asset/imagebased/image/baseiso_test.go (2)

52-58: 💤 Low value

Redundant manual env var restoration in defer.

t.Setenv automatically restores the previous value when the test completes, so manually restoring XDG_CACHE_HOME and OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE in the defer is unnecessary. Only the os.RemoveAll(tmpPath) cleanup is needed.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pkg/asset/imagebased/image/baseiso_test.go` around lines 52 - 58, The defer
in the test currently manually restores environment variables that were set with
t.Setenv (XDG_CACHE_HOME and OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE); remove those
manual t.Setenv restore calls from the deferred function and only perform the
filesystem cleanup (os.RemoveAll(tmpPath)) there so t.Setenv can handle env
restoration automatically (look for the defer func containing t.Setenv and
os.RemoveAll in baseiso_test.go).

17-28: ⚖️ Poor tradeoff

Test coverage gap: the non-override code path is untested.

The test only covers the OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE branch. The primary production code path that calls downloadBaseIso()assetrhcos.GetMetalArtifact() has no unit test coverage. Consider adding a test case for the non-override path, or confirm that integration tests adequately cover this functionality.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pkg/asset/imagebased/image/baseiso_test.go` around lines 17 - 28, Add a unit
test path in TestBaseIso_Generate that exercises the non-override branch by
leaving OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE unset/empty and asserting the code
calls downloadBaseIso which in turn uses assetrhcos.GetMetalArtifact; mock or
stub assetrhcos.GetMetalArtifact (and any download or HTTP calls) to return a
controlled filename/reader and verify expectedBaseIsoFilename and behavior for
the downloadBaseIso path, ensuring the non-override production flow is covered
(reference TestBaseIso_Generate, OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE,
downloadBaseIso, assetrhcos.GetMetalArtifact).
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@pkg/asset/imagebased/image/baseiso.go`:
- Around line 88-94: The code uses metal.Formats["iso"] without verifying
format.Disk is non-nil, risking a nil pointer when accessing
format.Disk.Location and format.Disk.Sha256; update the logic after retrieving
format (from metal.Formats["iso"]) to check that format.Disk != nil and return a
clear error (including archName) if it's nil, before using format.Disk to set
url and sha.

---

Nitpick comments:
In `@pkg/asset/imagebased/image/baseiso_test.go`:
- Around line 52-58: The defer in the test currently manually restores
environment variables that were set with t.Setenv (XDG_CACHE_HOME and
OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE); remove those manual t.Setenv restore calls
from the deferred function and only perform the filesystem cleanup
(os.RemoveAll(tmpPath)) there so t.Setenv can handle env restoration
automatically (look for the defer func containing t.Setenv and os.RemoveAll in
baseiso_test.go).
- Around line 17-28: Add a unit test path in TestBaseIso_Generate that exercises
the non-override branch by leaving OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE
unset/empty and asserting the code calls downloadBaseIso which in turn uses
assetrhcos.GetMetalArtifact; mock or stub assetrhcos.GetMetalArtifact (and any
download or HTTP calls) to return a controlled filename/reader and verify
expectedBaseIsoFilename and behavior for the downloadBaseIso path, ensuring the
non-override production flow is covered (reference TestBaseIso_Generate,
OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE, downloadBaseIso,
assetrhcos.GetMetalArtifact).

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 32baf4ab-59a7-4cb3-b80f-00457ff08a03

📥 Commits

Reviewing files that changed from the base of the PR and between 43933d0 and 1f8983c.

📒 Files selected for processing (2)
  • pkg/asset/imagebased/image/baseiso.go
  • pkg/asset/imagebased/image/baseiso_test.go

andfasano added 2 commits May 7, 2026 10:17
- removed CoreOSBuildFetcher, defaultCoreOSStreamGetter and streamGetter (replaced by a direct call to rhcos.FetchCoreOSBuild)
- removed OSImage/OSImageLocation from ClusterInfo
@andfasano andfasano force-pushed the nodejoiner-use-embedded-rhcos-data branch from df11856 to d1b6a22 Compare May 7, 2026 14:17
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
pkg/asset/imagebased/image/baseiso_test.go (1)

17-71: 💤 Low value

Test coverage reduced to only the override scenario.

The test now only covers the OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE path. The previous architecture-specific and default cases appear to have been removed. If the default path (non-override) is critical for this asset, consider adding a test case that exercises the GetMetalArtifact fallback, or confirm that this path is adequately covered by integration tests or tests in pkg/asset/rhcos/iso_test.go.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pkg/asset/imagebased/image/baseiso_test.go` around lines 17 - 71, The test
TestBaseIso_Generate was narrowed to only the
OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE path; restore coverage by adding cases
exercising the default (no override) flow and the architecture-specific fallback
that exercises BaseIso.Generate's call to GetMetalArtifact (or the rhcos ISO
retrieval path), e.g., add test cases where OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE
is empty and where arch-specific behavior is required, create appropriate
httptest servers or mocks for GetMetalArtifact responses, and assert the
resulting baseIso.File.Filename matches the expected default/arch filenames;
reference TestBaseIso_Generate and BaseIso.Generate (and GetMetalArtifact/rhcos
ISO retrieval) when locating the code to extend.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@pkg/asset/imagebased/image/baseiso_test.go`:
- Around line 17-71: The test TestBaseIso_Generate was narrowed to only the
OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE path; restore coverage by adding cases
exercising the default (no override) flow and the architecture-specific fallback
that exercises BaseIso.Generate's call to GetMetalArtifact (or the rhcos ISO
retrieval path), e.g., add test cases where OPENSHIFT_INSTALL_OS_IMAGE_OVERRIDE
is empty and where arch-specific behavior is required, create appropriate
httptest servers or mocks for GetMetalArtifact responses, and assert the
resulting baseIso.File.Filename matches the expected default/arch filenames;
reference TestBaseIso_Generate and BaseIso.Generate (and GetMetalArtifact/rhcos
ISO retrieval) when locating the code to extend.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 666a873c-81aa-4c42-b813-62467f541fc3

📥 Commits

Reviewing files that changed from the base of the PR and between 1f8983c and d1b6a22.

📒 Files selected for processing (14)
  • pkg/asset/agent/image/agentimage.go
  • pkg/asset/agent/image/baseiso.go
  • pkg/asset/agent/image/ignition.go
  • pkg/asset/agent/image/unconfigured_ignition.go
  • pkg/asset/agent/joiner/clusterinfo.go
  • pkg/asset/agent/joiner/clusterinfo_test.go
  • pkg/asset/imagebased/image/baseiso.go
  • pkg/asset/imagebased/image/baseiso_test.go
  • pkg/asset/rhcos/iso.go
  • pkg/asset/rhcos/iso_test.go
  • pkg/asset/rhcos/releaseextract.go
  • pkg/infrastructure/baremetal/bootstrap.go
  • pkg/nodejoiner/.claude/skills/nodejoiner-command/SKILL.md
  • pkg/nodejoiner/.claude/skills/nodejoiner-command/acceptance/coreos-bootimages-data.md
💤 Files with no reviewable changes (1)
  • pkg/asset/agent/joiner/clusterinfo.go
✅ Files skipped from review due to trivial changes (3)
  • pkg/nodejoiner/.claude/skills/nodejoiner-command/acceptance/coreos-bootimages-data.md
  • pkg/nodejoiner/.claude/skills/nodejoiner-command/SKILL.md
  • pkg/asset/agent/image/unconfigured_ignition.go
🚧 Files skipped from review as they are similar to previous changes (2)
  • pkg/asset/rhcos/releaseextract.go
  • pkg/asset/imagebased/image/baseiso.go

@andfasano
Copy link
Copy Markdown
Contributor Author

/retest

@pablintino
Copy link
Copy Markdown
Contributor

/retest-required

@pablintino
Copy link
Copy Markdown
Contributor

I don't have powers here to approve or lgtm, but based on the Slack discussions we have had this change makes total sense from my point of view.

@andfasano andfasano changed the title MCO-2200: refactored node-joiner use embedded rhcos data MCO-2200: refactored node-joiner to use embedded rhcos data May 8, 2026
@andfasano
Copy link
Copy Markdown
Contributor Author

/retest

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented May 8, 2026

@andfasano: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-agent-4control-ipv4 d1b6a22 link false /test e2e-agent-4control-ipv4
ci/prow/e2e-metal-ipi-ovn-dualstack d1b6a22 link false /test e2e-metal-ipi-ovn-dualstack
ci/prow/e2e-metal-ipi-ovn-virtualmedia d1b6a22 link false /test e2e-metal-ipi-ovn-virtualmedia
ci/prow/e2e-agent-two-node-fencing-ipv4 d1b6a22 link false /test e2e-agent-two-node-fencing-ipv4
ci/prow/e2e-metal-assisted d1b6a22 link false /test e2e-metal-assisted
ci/prow/e2e-agent-compact-ipv4-iso-no-registry d1b6a22 link false /test e2e-agent-compact-ipv4-iso-no-registry
ci/prow/e2e-metal-ipi-ovn-swapped-hosts d1b6a22 link false /test e2e-metal-ipi-ovn-swapped-hosts
ci/prow/e2e-metal-ovn-two-node-fencing d1b6a22 link false /test e2e-metal-ovn-two-node-fencing
ci/prow/e2e-agent-compact-ipv4-appliance-diskimage d1b6a22 link false /test e2e-agent-compact-ipv4-appliance-diskimage
ci/prow/e2e-agent-compact-ipv4-none-platform d1b6a22 link false /test e2e-agent-compact-ipv4-none-platform
ci/prow/e2e-metal-ipi-ovn d1b6a22 link false /test e2e-metal-ipi-ovn
ci/prow/e2e-agent-compact-ipv4 d1b6a22 link true /test e2e-agent-compact-ipv4
ci/prow/e2e-metal-single-node-live-iso d1b6a22 link false /test e2e-metal-single-node-live-iso
ci/prow/e2e-aws-ovn d1b6a22 link true /test e2e-aws-ovn
ci/prow/e2e-agent-5control-ipv4 d1b6a22 link false /test e2e-agent-5control-ipv4
ci/prow/e2e-agent-sno-ipv4-pxe d1b6a22 link false /test e2e-agent-sno-ipv4-pxe

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants