DPTP-4340: Remove direct mirroring to registry.ci.openshift.org, consolidate to single promotion step
Removes the direct mirroring step to registry.ci.openshift.org and consolidates promotion into a single step that handles both quay.io mirroring and tagging.
The promotion now:
(1) mirrors to quay.io/openshift/ci using oc image mirror, then
(2) tags in registry.ci.openshift.org from quay-proxy.ci.openshift.org using oc tag.
/hold /cc @Prucek @openshift/test-platform
Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.
For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.
This repository is configured in: LGTM mode
@deepsm007: This pull request references DPTP-4340 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.21.0" version, but no target version was set.
In response to this:
Removes the direct mirroring step to
registry.ci.openshift.organd consolidates promotion into a single step that handles both quay.io mirroring and tagging.The promotion now: (1) mirrors to
quay.io/openshift/ciusingoc image mirror, then (2) tags inregistry.ci.openshift.orgfromquay-proxy.ci.openshift.orgusingoc tag./hold /cc @Prucek @openshift/test-platform
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.
Walkthrough
Removed the generic promotion step from defaults; promotion is now handled only via the quay-specific promotion path (and logging when RegistryOverride is set), with corresponding test expectation updated.
Changes
| Cohort / File(s) | Change Summary |
|---|---|
Defaults implementation pkg/defaults/defaults.go |
Removed addition of a generic promotion step that used registryDomain(config.PromotionConfiguration), api.DefaultMirrorFunc, and api.DefaultTargetNameFunc; flow now relies on the quay-specific promotion step or logs when RegistryOverride prevents promotion. |
Unit test update pkg/defaults/defaults_test.go |
Updated TestFromConfig "promote" case to expect only "[promotion-quay]" in post-build steps (removed expectation of standalone "[promotion]"). |
Estimated code review effort
๐ฏ 2 (Simple) | โฑ๏ธ ~10 minutes
- Inspect
pkg/defaults/defaults.goto ensure no remaining references assume the generic promotion step exists. - Run/verify updated unit test
pkg/defaults/defaults_test.goand check for other tests that might assert the old behavior.
โจ Finishing touches
- [ ] ๐ Generate docstrings
๐งช Generate unit tests (beta)
- [ ] Create PR with unit tests
- [ ] Post copyable unit tests in a comment
๐ Recent review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
Cache: Disabled due to data retention organization setting
Knowledge base: Disabled due to Reviews -> Disable Knowledge Base setting
๐ฅ Commits
Reviewing files that changed from the base of the PR and between 6f270d2a6188278f8c13b9cb29c1a2e96b98f685 and 661cd2f9f5d5ea27fac1fea59868dd58b993b483.
๐ Files selected for processing (1)
-
pkg/defaults/defaults_test.go(1 hunks)
๐งฐ Additional context used
๐ Path-based instructions (1)
**
โ๏ธ CodeRabbit configuration file
-Focus on major issues impacting performance, readability, maintainability and security. Avoid nitpicks and avoid verbosity.
Files:
-
pkg/defaults/defaults_test.go
๐ Additional comments (1)
pkg/defaults/defaults_test.go (1)
1736-1736: LGTM! Test expectation correctly updated.The test expectation now reflects the consolidated promotion flow where only the
[promotion-quay]step executes post-build, removing the redundant generic[promotion]step. This aligns with the PR objective to consolidate promotion into a single step.
Comment @coderabbitai help to get the list of available commands and usage tips.
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: deepsm007
The full list of commands accepted by this bot can be found here.
The pull request process is described here
- ~~OWNERS~~ [deepsm007]
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment
/pipeline required
Scheduling required tests: /test e2e
Scheduling tests matching the pipeline_run_if_changed or not excluded by pipeline_skip_if_only_changed parameters:
/test integration-optional-test
@deepsm007: The following test 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/breaking-changes | 661cd2f9f5d5ea27fac1fea59868dd58b993b483 | link | false | /test breaking-changes |
Full PR test history. Your PR dashboard.
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.
when we merge this only the X.Y-quay IS will stay, is that what we want? Or do we want the current X.Y IS to use QCI images https://github.com/openshift/ci-tools/blob/main/pkg/api/promotion.go#L114