Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OCPBUGS-46412: Separate CPO containerfiles #5285

Open
wants to merge 1 commit into
base: release-4.17
Choose a base branch
from

Conversation

celebdor
Copy link
Contributor

What this PR does / why we need it:

ART machinery checks that the FROM images are consistent in the release payload. Since the Control Plane Operator does go in the release payload, the work I did to have the FROM image references be parametrized for Konflux, trips it up.

This PR separates the container files into:

  • Containerfile.control-plane: For Konflux, using RH catalog/brew
  • Dockerfile.control-plane: For ART/release-payload

To help developers avoid the situation where one changes one but not the other, this commit adds a git pre-commit hook that enforces the only differences to be in the "^FROM" lines.

In order to install this pre-commit hook, one can run:

pipx install pre-commit
pre-commit install

Then, any new commit that the developer attempts will have to conform to the new hook (and a couple more I added like no whitespace at the end).

Which issue(s) this PR fixes (optional, use fixes #<issue_number>(, fixes #<issue_number>, ...) format, where issue_number might be a GitHub issue, or a Jira story:
Fixes #

Checklist

  • Subject and description added to both, commit and PR.
  • Relevant issues have been referenced.
  • This change includes docs.
  • This change includes unit tests.

@openshift-ci-robot openshift-ci-robot added jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Dec 13, 2024
@openshift-ci-robot
Copy link

@celebdor: This pull request references Jira Issue OCPBUGS-44326, which is invalid:

  • expected the bug to target either version "4.17." or "openshift-4.17.", but it targets "4.19.0" instead
  • expected the bug to be in one of the following states: NEW, ASSIGNED, POST, but it is Verified instead
  • expected Jira Issue OCPBUGS-44326 to depend on a bug targeting a version in 4.18.0 and in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but no dependents were found

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

In response to this:

What this PR does / why we need it:

ART machinery checks that the FROM images are consistent in the release payload. Since the Control Plane Operator does go in the release payload, the work I did to have the FROM image references be parametrized for Konflux, trips it up.

This PR separates the container files into:

  • Containerfile.control-plane: For Konflux, using RH catalog/brew
  • Dockerfile.control-plane: For ART/release-payload

To help developers avoid the situation where one changes one but not the other, this commit adds a git pre-commit hook that enforces the only differences to be in the "^FROM" lines.

In order to install this pre-commit hook, one can run:

pipx install pre-commit
pre-commit install

Then, any new commit that the developer attempts will have to conform to the new hook (and a couple more I added like no whitespace at the end).

Which issue(s) this PR fixes (optional, use fixes #<issue_number>(, fixes #<issue_number>, ...) format, where issue_number might be a GitHub issue, or a Jira story:
Fixes #

Checklist

  • Subject and description added to both, commit and PR.
  • Relevant issues have been referenced.
  • This change includes docs.
  • This change includes unit tests.

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 requested review from enxebre and sjenning December 13, 2024 14:03
@openshift-ci openshift-ci bot added area/ci-tooling Indicates the PR includes changes for CI or tooling and removed do-not-merge/needs-area labels Dec 13, 2024
@celebdor
Copy link
Contributor Author

/jira cherrypick OCPBUGS-46394

@openshift-ci-robot
Copy link

@celebdor: Jira Issue OCPBUGS-46394 has been cloned as Jira Issue OCPBUGS-46412. Will retitle bug to link to clone.
/retitle OCPBUGS-46412: OCPBUGS-44326: Separate CPO containerfiles

In response to this:

/jira cherrypick OCPBUGS-46394

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 changed the title OCPBUGS-44326: Separate CPO containerfiles OCPBUGS-46412: OCPBUGS-44326: Separate CPO containerfiles Dec 13, 2024
@openshift-ci-robot
Copy link

@celebdor: This pull request references Jira Issue OCPBUGS-46412, which is invalid:

  • expected dependent Jira Issue OCPBUGS-46394 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is ON_QA instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

In response to this:

What this PR does / why we need it:

ART machinery checks that the FROM images are consistent in the release payload. Since the Control Plane Operator does go in the release payload, the work I did to have the FROM image references be parametrized for Konflux, trips it up.

This PR separates the container files into:

  • Containerfile.control-plane: For Konflux, using RH catalog/brew
  • Dockerfile.control-plane: For ART/release-payload

To help developers avoid the situation where one changes one but not the other, this commit adds a git pre-commit hook that enforces the only differences to be in the "^FROM" lines.

In order to install this pre-commit hook, one can run:

pipx install pre-commit
pre-commit install

Then, any new commit that the developer attempts will have to conform to the new hook (and a couple more I added like no whitespace at the end).

Which issue(s) this PR fixes (optional, use fixes #<issue_number>(, fixes #<issue_number>, ...) format, where issue_number might be a GitHub issue, or a Jira story:
Fixes #

Checklist

  • Subject and description added to both, commit and PR.
  • Relevant issues have been referenced.
  • This change includes docs.
  • This change includes unit tests.

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.

@celebdor
Copy link
Contributor Author

/retitle OCPBUGS-46412: Separate CPO containerfiles

@openshift-ci openshift-ci bot changed the title OCPBUGS-46412: OCPBUGS-44326: Separate CPO containerfiles OCPBUGS-46412: Separate CPO containerfiles Dec 13, 2024
@bryan-cox
Copy link
Member

/approve

Copy link
Contributor

openshift-ci bot commented Dec 13, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: bryan-cox, celebdor

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

The pull request process is described here

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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 13, 2024
ART machinery checks that the FROM images are consistent in the release
payload. Since the Control Plane Operator does go in the release
payload, the work I did to have the FROM image references be
parametrized for Konflux, trips it up.

This PR separates the container files into:
- Containerfile.control-plane: For Konflux, using RH catalog/brew
- Dockerfile.control-plane: For ART/release-payload

To help developers avoid the situation where one changes one but not the
other, this commit adds a git pre-commit hook that enforces the only
differences to be in the "^FROM" lines.

In order to install this pre-commit hook, one can run:

    pipx install pre-commit
    pre-commit install

Then, any new commit that the developer attempts will have to conform to
the new hook (and a couple more I added like no whitespace at the end).

Signed-off-by: Antoni Segura Puimedon <[email protected]>
@celebdor
Copy link
Contributor Author

/jira refresh

@openshift-ci-robot openshift-ci-robot added jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. and removed jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Dec 16, 2024
@openshift-ci-robot
Copy link

@celebdor: This pull request references Jira Issue OCPBUGS-46412, which is valid. The bug has been moved to the POST state.

7 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.17.z) matches configured target version for branch (4.17.z)
  • bug is in the state New, which is one of the valid states (NEW, ASSIGNED, POST)
  • release note text is set and does not match the template
  • dependent bug Jira Issue OCPBUGS-46394 is in the state Verified, which is one of the valid states (VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA))
  • dependent Jira Issue OCPBUGS-46394 targets the "4.18.0" version, which is one of the valid target versions: 4.18.0
  • bug has dependents

No GitHub users were found matching the public email listed for the QA contact in Jira ([email protected]), skipping review request.

The bug has been updated to refer to the pull request using the external bug tracker.

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.

@bryan-cox
Copy link
Member

/retest

1 similar comment
@celebdor
Copy link
Contributor Author

/retest

Copy link
Contributor

@jparrill jparrill left a comment

Choose a reason for hiding this comment

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

Dropped some questions, otherwise lgtm

@@ -0,0 +1,27 @@
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_1.22 AS builder
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we move from 1.22 to 1.23 recently.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is for 4.17. We were still on 1.22

ARG BASE_IMAGE=registry.ci.openshift.org/ocp/4.18:base-rhel9

FROM ${EL9_BUILD_IMAGE} AS builder
FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.22-openshift-4.17 AS builder
Copy link
Contributor

Choose a reason for hiding this comment

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

Same than above

ARG BASE_IMAGE=registry.ci.openshift.org/ocp/4.18:base-rhel9

FROM ${EL9_BUILD_IMAGE} AS builder
FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.22-openshift-4.17 AS builder
Copy link
Contributor

Choose a reason for hiding this comment

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

It should be 4.17? or 4.18?
Also the version for 1.23 on Golang side

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is for 4.17. We were still on 1.22

@jparrill
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Dec 17, 2024
@devguyio
Copy link
Contributor

/lgtm

@openshift-ci-robot
Copy link

/retest-required

Remaining retests: 0 against base HEAD 608f456 and 2 for PR HEAD b26589d in total

Copy link
Contributor

openshift-ci bot commented Dec 17, 2024

@celebdor: all tests passed!

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.

@celebdor
Copy link
Contributor Author

/retest-required

1 similar comment
@celebdor
Copy link
Contributor Author

/retest-required

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/ci-tooling Indicates the PR includes changes for CI or tooling jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. 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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants