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

Bug 1810184: Components using globs in Dockerfile COPY commands may break on OCP 4 #816

Conversation

p0lyn0mial
Copy link
Contributor

No description provided.

@openshift-ci-robot
Copy link

@p0lyn0mial: This pull request references Bugzilla bug 1810184, which is invalid:

  • expected dependent Bugzilla bug 1810182 to be in one of the following states: VERIFIED, RELEASE_PENDING, CLOSED (ERRATA), but it is ON_QA instead
  • expected dependent Bugzilla bug 1810182 to target the "4.4.0" release, but it targets "4.4.z" instead

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

In response to this:

Bug 1810184: Components using globs in Dockerfile COPY commands may break on OCP 4

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/test-infra repository.

@openshift-ci-robot openshift-ci-robot added the bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. label Apr 3, 2020
@p0lyn0mial
Copy link
Contributor Author

/assign @bparees @sttts

@p0lyn0mial
Copy link
Contributor Author

should mirror #808

COPY --from=builder /go/src/github.com/openshift/cluster-kube-apiserver-operator/bindata/bootkube/* /usr/share/bootkube/manifests/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-apiserver-operator/bindata/bootkube/bootstrap-manifests /usr/share/bootkube/manifests/bootstrap-manifests/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-apiserver-operator/bindata/bootkube/config /usr/share/bootkube/manifests/config/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-apiserver-operator/bindata/bootkube/manifests /usr/share/bootkube/manifests/manifests/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-apiserver-operator/cluster-kube-apiserver-operator /usr/bin/
COPY manifests/*.yaml /manifests/
Copy link
Contributor Author

Choose a reason for hiding this comment

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

surprise, we can't copy the whole directory as we did in master and 4.4 (COPY manifests /manifests) because it contains some JSON files to.

@p0lyn0mial p0lyn0mial changed the title Bug 1810184: Components using globs in Dockerfile COPY commands may break on OCP 4 [release-4.3] Bug 1810184: Components using globs in Dockerfile COPY commands may break on OCP 4 Apr 3, 2020
@sttts
Copy link
Contributor

sttts commented Apr 3, 2020

/lgtm
/approve

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Apr 3, 2020
@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: p0lyn0mial, sttts

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-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 3, 2020
@bparees bparees added bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. and removed bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. labels Apr 3, 2020
@bparees
Copy link
Contributor

bparees commented Apr 3, 2020

BZ overridden: covered by automated tests, low risk, needed for api.ci migration.

will let team review/lgtm.

@@ -5,8 +5,9 @@ ENV GO_PACKAGE github.com/openshift/cluster-kube-apiserver-operator
RUN make build --warn-undefined-variables

FROM registry.svc.ci.openshift.org/ocp/4.3:base
RUN mkdir -p /usr/share/bootkube/manifests /manifests
COPY --from=builder /go/src/github.com/openshift/cluster-kube-apiserver-operator/bindata/bootkube/* /usr/share/bootkube/manifests/
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@bparees out of curiosity does it mean that in the past the directory structure for bootkube was incorrect?

Copy link
Contributor

Choose a reason for hiding this comment

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

no, you were just reliant on how "docker" handles /* which is not the same as how buildah does. So it was fine as long as you were being built on docker. As we're switching CI to build things using buildah, your dockerfile would have stopped building the right thing.

Copy link
Contributor

Choose a reason for hiding this comment

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

sorry, you were reliant on imagebuilder behavior, not docker. docker+buildah work the same way.

Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

imagebuilder preserved the subdirs when doing a cp from foo/* whereas docker+buildah flatten the subdir when you use *

Copy link
Contributor Author

Choose a reason for hiding this comment

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

okay, I was just wondering why CI jobs were passing despite the destination dir being different. Thanks for explaining!

@crawford crawford changed the title [release-4.3] Bug 1810184: Components using globs in Dockerfile COPY commands may break on OCP 4 Bug 1810184: Components using globs in Dockerfile COPY commands may break on OCP 4 Apr 3, 2020
@crawford crawford added the cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. label Apr 3, 2020
@openshift-merge-robot openshift-merge-robot merged commit ab2a9b2 into openshift:release-4.3 Apr 3, 2020
@openshift-ci-robot
Copy link

@p0lyn0mial: All pull requests linked via external trackers have merged: openshift/cluster-kube-apiserver-operator#816. Bugzilla bug 1810184 has been moved to the MODIFIED state.

In response to this:

Bug 1810184: Components using globs in Dockerfile COPY commands may break on OCP 4

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/test-infra repository.

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. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. cherry-pick-approved Indicates a cherry-pick PR into a release branch has been approved by the release branch manager. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants