Skip to content

Add OMR v2 disconnected presubmit for mirror-registry#82430

Open
jbpratt wants to merge 2 commits into
openshift:mainfrom
jbpratt:work/omr-v2-presubmit
Open

Add OMR v2 disconnected presubmit for mirror-registry#82430
jbpratt wants to merge 2 commits into
openshift:mainfrom
jbpratt:work/omr-v2-presubmit

Conversation

@jbpratt

@jbpratt jbpratt commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add an optional /test omr-v2-disconnected-install presubmit for quay/mirror-registry
  • build the offline OMR v2 installer from the pull request commit using the complete repository context
  • extract and verify the pipeline archive, transfer it to the dedicated RHEL host, and verify checksum continuity before and after installation
  • reuse the existing disconnected AWS/OpenShift provisioning path and run OMR v2 validation only
  • preserve the existing quay/quay migration periodic's released-artifact fallback behavior
  • enable the Prow trigger plugin and authorize quay/mirror-registry for the aws-quay-qe cluster profile

Validation

  • make ci-operator-config SKIP_PULL=true
  • make jobs WHAT=quay/mirror-registry SKIP_PULL=true
  • make registry-metadata SKIP_PULL=true
  • make ci-operator-checkconfig SKIP_PULL=true
  • targeted strict Prow checkconfig with the generated jobs and merged plugin configuration
  • Bash syntax and warning-level ShellCheck for the changed command scripts
  • positive pipeline extraction and install fixtures
  • malformed archive, transfer checksum mismatch, and installed checksum mismatch rejection fixtures
  • released-download fallback fixture
  • generated job, full-checkout, and OWNERS symlink assertions
  • git diff --check

Environment-limited checks

  • The repository-wide make checkconfig SKIP_PULL=true reaches a local supplemental-directory stat /release/core-services/prow/02_config: invalid argument error; targeted strict Prow validation passes.
  • make validate-step-registry SKIP_PULL=true is locally blocked by the current resolver's unsupported -prow-config flag. Running the resolver directly proceeds through config and registry loading, then requires in-cluster credentials.
  • The 10-hour AWS disconnected installation workflow was not run locally.

Summary by CodeRabbit

Adds an optional omr-v2-disconnected-install presubmit for quay/mirror-registry. The workflow builds the PR’s OMR v2 pipeline image, transfers and verifies its offline archive on a dedicated RHEL host, then reuses the existing disconnected AWS/OpenShift provisioning path for OMR v2 validation.

Also preserves the released-artifact fallback for quay/quay, enables Prow triggering for quay/mirror-registry, and authorizes the repository for the aws-quay-qe cluster profile. The install flow now verifies archive checksums across transfer and installation, while supporting both PR-built and downloaded artifacts.

@coderabbitai

coderabbitai Bot commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Walkthrough

Changes

Adds a new OMR v2 mirror-registry CI configuration and disconnected AWS workflow. A preparation step publishes PR pipeline image references, while installation conditionally extracts, transfers, verifies, and installs the PR-built archive or downloads the official artifact.

OMR v2 pipeline integration

Layer / File(s) Summary
CI configuration and repository wiring
ci-operator/config/quay/mirror-registry/*, ci-operator/step-registry/cluster-profiles/cluster-profiles-config.yaml, core-services/prow/02_config/quay/mirror-registry/_pluginconfig.yaml
Adds the OMR v2 build and disconnected-install configuration, cluster repository access, ownership links, and trusted trigger configuration.
Pipeline image preparation
ci-operator/step-registry/quay/omr-v2/prepare-pipeline/*
Adds a step that validates OMR_V2_IMAGE and atomically publishes its pullspec for later installation.
Disconnected provisioning chain
ci-operator/step-registry/quay/aws-ipi-disconnected-omr-v2-provision/*
Runs pipeline preparation before the existing disconnected OMR v2-to-v3 provisioning chain.
Conditional artifact installation
ci-operator/step-registry/quay/omr-v2/install/*
Supports PR archive extraction, checksum verification, remote transfer, pipeline installation, runtime checksum validation, and fallback downloads.
Estimated code review effort: 4 (Complex) ~45 minutes

Possibly related PRs

  • openshift/release#82188: Defines the related disconnected OMR v2-to-v3 provisioning chain reused by this workflow.

Suggested labels: rehearsals-ack

Suggested reviewers: petr-muller, marcusk19


Important

Pre-merge checks failed

Please resolve all errors before merging. Addressing warnings is optional.

❌ Failed checks (1 error)

Check name Status Explanation Resolution
No-Sensitive-Data-In-Logs ❌ Error quay-omr-v2-install-commands.sh logs https://${registry_hostname}:8443/health/instance, exposing an internal hostname in CI output. Remove the hostname from the log message and keep the health-check URL only in the curl command; password redaction can stay as-is.
✅ Passed checks (14 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: adding an OMR v2 disconnected presubmit for mirror-registry.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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 The PR only changes YAML and shell step/config files; no It/Describe/Context/When test titles were added, and the new job names are static.
Test Structure And Quality ✅ Passed No Ginkgo/Go test code changed; the PR only updates CI config, YAML, and bash step scripts.
Microshift Test Compatibility ✅ Passed No Ginkgo e2e tests were added; the diff is CI config/step scripts only, so MicroShift compatibility is not applicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed No new Ginkgo e2e test code was added; the PR changes only CI config, step-registry YAML, OWNERS symlinks, and shell scripts.
Topology-Aware Scheduling Compatibility ✅ Passed PASS: The PR only adds CI/job config and step scripts; no deployment manifests, controllers, or topology-sensitive scheduling fields (affinity, nodeSelector, spread, PDB) were introduced.
Ote Binary Stdout Contract ✅ Passed The PR only changes CI YAML, step-registry shell scripts, and OWNERS/metadata files; no Go OTE binary entrypoints or process-level stdout code were touched.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed No new Ginkgo e2e tests were added; the diff is CI YAML/bash only, with no IPv4-specific test code or public-internet test calls.
No-Weak-Crypto ✅ Passed No MD5/SHA1/DES/RC4/3DES/Blowfish/ECB, custom crypto, or secret/token comparisons were introduced; only sha256sum and openssl rand are used.
Container-Privileges ✅ Passed The touched CI/job files and scripts contain no privileged pod settings, host namespaces, SYS_ADMIN, or allowPrivilegeEscalation; targeted scans found none.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@openshift-ci
openshift-ci Bot requested review from Marcusk19 and petr-muller July 24, 2026 20:39
@openshift-ci

openshift-ci Bot commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: jbpratt
Once this PR has been reviewed and has the lgtm label, please assign danilo-gemoli 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

@jbpratt

jbpratt commented Jul 24, 2026

Copy link
Copy Markdown
Contributor Author

/pj-rehearse pull-ci-quay-mirror-registry-main-omr-v2-disconnected-install

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@jbpratt: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

[REHEARSALNOTIFIER]
@jbpratt: the pj-rehearse plugin accommodates running rehearsal tests for the changes in this PR. Expand 'Interacting with pj-rehearse' for usage details. The following rehearsable tests have been affected by this change:

Test name Repo Type Reason
pull-ci-quay-mirror-registry-main-omr-v2-disconnected-install quay/mirror-registry presubmit Presubmit changed
pull-ci-quay-mirror-registry-main-omr-v2-images quay/mirror-registry presubmit Presubmit changed
periodic-ci-quay-quay-master-omr-v2-upgrade-v3-disconnected-install N/A periodic Registry content changed
Interacting with pj-rehearse

Comment: /pj-rehearse to run up to 5 rehearsals
Comment: /pj-rehearse skip to opt-out of rehearsals
Comment: /pj-rehearse {test-name}, with each test separated by a space, to run one or more specific rehearsals
Comment: /pj-rehearse more to run up to 10 rehearsals
Comment: /pj-rehearse max to run up to 25 rehearsals
Comment: /pj-rehearse auto-ack to run up to 5 rehearsals, and add the rehearsals-ack label on success
Comment: /pj-rehearse list to get an up-to-date list of affected jobs
Comment: /pj-rehearse abort to abort all active rehearsals
Comment: /pj-rehearse network-access-allowed to allow rehearsals of tests that have the restrict_network_access field set to false. This must be executed by an openshift org member who is not the PR author

Once you are satisfied with the results of the rehearsals, comment: /pj-rehearse ack to unblock merge. When the rehearsals-ack label is present on your PR, merge will no longer be blocked by rehearsals.
If you would like the rehearsals-ack label removed, comment: /pj-rehearse reject to re-block merging.

@jbpratt

jbpratt commented Jul 24, 2026

Copy link
Copy Markdown
Contributor Author

/pj-rehearse pull-ci-quay-mirror-registry-main-omr-v2-disconnected-install

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@jbpratt: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@coderabbitai coderabbitai Bot left a comment

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.

Actionable comments posted: 1

🤖 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
`@ci-operator/step-registry/quay/omr-v2/prepare-pipeline/quay-omr-v2-prepare-pipeline-commands.sh`:
- Line 11: Update the publication and cleanup logic around the shared artifact
and the temporary file: stop deleting the existing destination before creating
or moving the temporary file, use mv -f to atomically replace
${SHARED_DIR}/omr_v2_pipeline_image, and ensure cleanup removes only the
temporary file. Set publication state so an interruption after a successful
rename cannot remove the destination.
🪄 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 YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: 160a23ab-6a2b-4eee-b5ba-1864751aab50

📥 Commits

Reviewing files that changed from the base of the PR and between 8cd62e5 and 818a9b6.

📒 Files selected for processing (7)
  • ci-operator/step-registry/quay/aws-ipi-disconnected-omr-v2-provision/quay-aws-ipi-disconnected-omr-v2-provision-chain.yaml
  • ci-operator/step-registry/quay/omr-v2/install/quay-omr-v2-install-commands.sh
  • ci-operator/step-registry/quay/omr-v2/install/quay-omr-v2-install-ref.yaml
  • ci-operator/step-registry/quay/omr-v2/prepare-pipeline/OWNERS
  • ci-operator/step-registry/quay/omr-v2/prepare-pipeline/quay-omr-v2-prepare-pipeline-commands.sh
  • ci-operator/step-registry/quay/omr-v2/prepare-pipeline/quay-omr-v2-prepare-pipeline-ref.metadata.json
  • ci-operator/step-registry/quay/omr-v2/prepare-pipeline/quay-omr-v2-prepare-pipeline-ref.yaml
🚧 Files skipped from review as they are similar to previous changes (3)
  • ci-operator/step-registry/quay/omr-v2/install/quay-omr-v2-install-ref.yaml
  • ci-operator/step-registry/quay/aws-ipi-disconnected-omr-v2-provision/quay-aws-ipi-disconnected-omr-v2-provision-chain.yaml
  • ci-operator/step-registry/quay/omr-v2/install/quay-omr-v2-install-commands.sh


pipeline_image_file="${SHARED_DIR}/omr_v2_pipeline_image"
pipeline_image_tmp=""
published=false

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.

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

Preserve the destination during atomic publication.

Line 41 deletes the existing shared artifact before the temporary file is created. If mktemp, printf, chmod, mv, or an interruption fails afterward, cleanup also removes the destination; because published=true is assigned only after mv, a successful rename can even be undone by TERM in that window. Let mv -f replace the destination atomically and clean up only the temporary file.

This follows the stated atomic-publication objective and the downstream installer contract for ${SHARED_DIR}/omr_v2_pipeline_image.

Proposed fix
-published=false
-
 cleanup() {
     local status=$?

     trap - EXIT TERM
     set +o errexit
     if [[ -n "${pipeline_image_tmp}" ]]; then
         rm -f -- "${pipeline_image_tmp}"
     fi
-    if [[ "${published}" != true ]]; then
-        rm -f -- "${pipeline_image_file}"
-    fi
     exit "${status}"
 }

-rm -f -- "${pipeline_image_file}"
 pipeline_image_tmp=$(mktemp "${SHARED_DIR}/.omr_v2_pipeline_image.XXXXXX")
 printf '%s\n' "${OMR_V2_IMAGE}" > "${pipeline_image_tmp}"
 chmod 0644 "${pipeline_image_tmp}"
 mv -f -- "${pipeline_image_tmp}" "${pipeline_image_file}"
 pipeline_image_tmp=""
-published=true

Also applies to: 21-23, 41-47

🤖 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
`@ci-operator/step-registry/quay/omr-v2/prepare-pipeline/quay-omr-v2-prepare-pipeline-commands.sh`
at line 11, Update the publication and cleanup logic around the shared artifact
and the temporary file: stop deleting the existing destination before creating
or moving the temporary file, use mv -f to atomically replace
${SHARED_DIR}/omr_v2_pipeline_image, and ensure cleanup removes only the
temporary file. Set publication state so an interruption after a successful
rename cannot remove the destination.

@jbpratt

jbpratt commented Jul 25, 2026

Copy link
Copy Markdown
Contributor Author

/pj-rehearse pull-ci-quay-mirror-registry-main-omr-v2-disconnected-install

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@jbpratt: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@jbpratt

jbpratt commented Jul 25, 2026

Copy link
Copy Markdown
Contributor Author

/pj-rehearse pull-ci-quay-mirror-registry-main-omr-v2-disconnected-install

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@jbpratt: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-ci

openshift-ci Bot commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

@jbpratt: 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.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant