Read workload image from WORKLOAD_IMAGE env var (fix disconnected CI) - #60
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
🚧 Files skipped from review as they are similar to previous changes (3)
📝 WalkthroughWalkthroughThe workload image is now read from ChangesWorkload image configuration
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
PR Summary by QodoUse UBI9 ubi-minimal as default workload image for disconnected CI
AI Description
Diagram
High-Level Assessment
Files changed (1)
|
Code Review by Qodo
Context used✅ Compliance rules (platform):
13 rules 1.
|
The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Mirror ubi-minimal via oc-mirror additionalImages and create an ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror. This follows the kueue-operator disconnected install pattern (kueue-operator/disconnected/install). Companion PR: medik8s/system-tests#60 Co-Authored-By: Claude <noreply@anthropic.com>
914b539 to
2853a1a
Compare
The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Mirror ubi-minimal via oc-mirror additionalImages and create an ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror. This follows the kueue-operator disconnected install pattern (kueue-operator/disconnected/install). Write the image reference to SHARED_DIR/workload_image so the test step can export WORKLOAD_IMAGE. Future image changes only need this one PR (the Go code reads the env var). Companion PR: medik8s/system-tests#60 Co-Authored-By: Claude <noreply@anthropic.com>
The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Changes: - medik8s-lib: write workload image to SHARED_DIR/workload_image (single source of truth for all environments) - Connected config (4.22-konflux): export WORKLOAD_IMAGE from SHARED_DIR in all 14 e2e-test steps; add medik8s-lib ref to SBR-EFS job that was using individual steps instead of the medik8s-setup chain - Disconnected config (4.22-disconnected): export WORKLOAD_IMAGE from SHARED_DIR in both e2e-test steps (already present) - Disconnected catalogsource step: add additionalImages for ubi-minimal in oc-mirror config; create ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror (kueue-operator pattern) To change the workload image: edit ONE line in medik8s-lib-commands.sh and (for disconnected) the additionalImages entry. Both are in this repo, same PR. Companion PR: medik8s/system-tests#60 Co-Authored-By: Claude <noreply@anthropic.com>
2853a1a to
2eba054
Compare
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 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 `@README.md`:
- Around line 45-48: Update the later make run-tests example in README.md to
also export WORKLOAD_IMAGE, using the documented local image value, alongside
KUBECONFIG and the test selectors.
In `@tests/internal/medik8sparams/const.go`:
- Around line 17-23: Validate WORKLOAD_IMAGE during initialization of
DefaultWorkloadImage and fail immediately when it is unset or empty, rather than
propagating an invalid image value. Do not add a public-registry fallback;
preserve the explicitly configured mirror-specific image for disconnected
environments.
🪄 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: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 19a35644-8d26-4dba-9a0e-c61b5b4586d5
📒 Files selected for processing (4)
README.mdtests/far-operator/internal/farparams/const.gotests/internal/medik8sparams/const.gotests/snr-operator/internal/snrparams/const.go
🚧 Files skipped from review as they are similar to previous changes (2)
- tests/far-operator/internal/farparams/const.go
- tests/snr-operator/internal/snrparams/const.go
The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Changes: - medik8s-lib: write workload image to SHARED_DIR/workload_image (single source of truth for all environments) - Connected config (4.22-konflux): export WORKLOAD_IMAGE from SHARED_DIR in all 14 e2e-test steps; add medik8s-lib ref to SBR-EFS job that was using individual steps instead of the medik8s-setup chain - Disconnected config (4.22-disconnected): export WORKLOAD_IMAGE from SHARED_DIR in both e2e-test steps (already present) - Disconnected catalogsource step: add additionalImages for ubi-minimal in oc-mirror config; create ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror (kueue-operator pattern) To change the workload image: edit ONE line in medik8s-lib-commands.sh and (for disconnected) the additionalImages entry. Both are in this repo, same PR. Companion PR: medik8s/system-tests#60 Co-Authored-By: Claude <noreply@anthropic.com>
The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Changes: - medik8s-lib: write workload image to SHARED_DIR/workload_image (single source of truth for all environments) - Connected config (4.22-konflux): export WORKLOAD_IMAGE from SHARED_DIR in all 14 e2e-test steps; add medik8s-lib ref to SBR-EFS job that was using individual steps instead of the medik8s-setup chain - Disconnected config (4.22-disconnected): export WORKLOAD_IMAGE from SHARED_DIR in both e2e-test steps (already present) - Disconnected catalogsource step: add additionalImages for ubi-minimal in oc-mirror config; create ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror (kueue-operator pattern) To change the workload image: edit ONE line in medik8s-lib-commands.sh and (for disconnected) the additionalImages entry. Both are in this repo, same PR. Companion PR: medik8s/system-tests#60 Co-Authored-By: Claude <noreply@anthropic.com>
The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Changes: - medik8s-lib: write workload image to SHARED_DIR/workload_image (single source of truth for all environments) - Connected config (4.22-konflux): export WORKLOAD_IMAGE from SHARED_DIR in all 14 e2e-test steps; add medik8s-lib ref to SBR-EFS job that was using individual steps instead of the medik8s-setup chain - Disconnected config (4.22-disconnected): export WORKLOAD_IMAGE from SHARED_DIR in both e2e-test steps (already present) - Disconnected catalogsource step: add additionalImages for ubi-minimal in oc-mirror config; create ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror (kueue-operator pattern) To change the workload image: edit ONE line in medik8s-lib-commands.sh and (for disconnected) the additionalImages entry. Both are in this repo, same PR. Companion PR: medik8s/system-tests#60 Co-authored-by: Claude <noreply@anthropic.com>
|
/test 4.22-disconnected-e2e-far-aws-disconnected |
…shift#82523) The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Changes: - medik8s-lib: write workload image to SHARED_DIR/workload_image (single source of truth for all environments) - Connected config (4.22-konflux): export WORKLOAD_IMAGE from SHARED_DIR in all 14 e2e-test steps; add medik8s-lib ref to SBR-EFS job that was using individual steps instead of the medik8s-setup chain - Disconnected config (4.22-disconnected): export WORKLOAD_IMAGE from SHARED_DIR in both e2e-test steps (already present) - Disconnected catalogsource step: add additionalImages for ubi-minimal in oc-mirror config; create ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror (kueue-operator pattern) To change the workload image: edit ONE line in medik8s-lib-commands.sh and (for disconnected) the additionalImages entry. Both are in this repo, same PR. Companion PR: medik8s/system-tests#60 Co-authored-by: Claude <noreply@anthropic.com>
The openshift/tools ImageStream does not exist on disconnected OCP clusters (Cluster Samples Operator is set to Removed). Switch to registry.access.redhat.com/ubi9/ubi-minimal via the WORKLOAD_IMAGE env var, which is set by the medik8s-lib Prow step (single source of truth in openshift/release, used by both connected and disconnected). No hardcoded image fallback in Go code. For local runs, set WORKLOAD_IMAGE manually (documented in README). Co-Authored-By: Claude <noreply@anthropic.com>
2eba054 to
665404b
Compare
|
/test 4.22-disconnected-e2e-far-aws-disconnected |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: razo7, ugreener 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 |
…shift#82523) The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Changes: - medik8s-lib: write workload image to SHARED_DIR/workload_image (single source of truth for all environments) - Connected config (4.22-konflux): export WORKLOAD_IMAGE from SHARED_DIR in all 14 e2e-test steps; add medik8s-lib ref to SBR-EFS job that was using individual steps instead of the medik8s-setup chain - Disconnected config (4.22-disconnected): export WORKLOAD_IMAGE from SHARED_DIR in both e2e-test steps (already present) - Disconnected catalogsource step: add additionalImages for ubi-minimal in oc-mirror config; create ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror (kueue-operator pattern) To change the workload image: edit ONE line in medik8s-lib-commands.sh and (for disconnected) the additionalImages entry. Both are in this repo, same PR. Companion PR: medik8s/system-tests#60 Co-authored-by: Claude <noreply@anthropic.com>
…shift#82523) The medik8s E2E destructive tests create workload pods using registry.access.redhat.com/ubi9/ubi-minimal to verify pod eviction after node remediation. On disconnected clusters this registry is unreachable. Changes: - medik8s-lib: write workload image to SHARED_DIR/workload_image (single source of truth for all environments) - Connected config (4.22-konflux): export WORKLOAD_IMAGE from SHARED_DIR in all 14 e2e-test steps; add medik8s-lib ref to SBR-EFS job that was using individual steps instead of the medik8s-setup chain - Disconnected config (4.22-disconnected): export WORKLOAD_IMAGE from SHARED_DIR in both e2e-test steps (already present) - Disconnected catalogsource step: add additionalImages for ubi-minimal in oc-mirror config; create ImageTagMirrorSet so CRI-O redirects pulls to the bastion mirror (kueue-operator pattern) To change the workload image: edit ONE line in medik8s-lib-commands.sh and (for disconnected) the additionalImages entry. Both are in this repo, same PR. Companion PR: medik8s/system-tests#60 Co-authored-by: Claude <noreply@anthropic.com>
Summary
Fix disconnected CI failures caused by
openshift/tools:latestnot existing on air-gapped clusters (Cluster Samples Operator is Removed). Replace the hardcoded image constant withWORKLOAD_IMAGEenv var, set by themedik8s-libProw step as the single source of truth for all environments.Changes
tests/internal/medik8sparams/const.go: Replace hardcodedDefaultWorkloadImageconstant withos.Getenv("WORKLOAD_IMAGE")(no fallback)tests/far-operator/internal/farparams/const.go: ChangeWorkloadTestImagefromconsttovar(required becauseDefaultWorkloadImageis now avar)tests/snr-operator/internal/snrparams/const.go: SameconsttovarchangeREADME.md: AddWORKLOAD_IMAGEto mandatory env vars with local-run exampleThe image is defined in ONE place:
medik8s-lib-commands.shin openshift/release. Both connected and disconnected CI read it fromSHARED_DIR/workload_image. No hardcoded image string in this repo.Companion PR: openshift/release#82523
Summary by CodeRabbit
New Features
WORKLOAD_IMAGEenvironment variable.Bug Fixes
WORKLOAD_IMAGEis missing or empty, instead of proceeding with an invalid image value.Documentation
WORKLOAD_IMAGE.