-
Notifications
You must be signed in to change notification settings - Fork 108
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
UPSTREAM: <carry>: openshift-hack/images/os/Dockerfile: Add io.openshift.build.versions, etc. #963
UPSTREAM: <carry>: openshift-hack/images/os/Dockerfile: Add io.openshift.build.versions, etc. #963
Conversation
@wking: the contents of this pull request could not be automatically validated. The following commits could not be validated and must be approved by a top-level approver:
|
52a62a0
to
df59e4c
Compare
@wking: the contents of this pull request could not be automatically validated. The following commits could not be validated and must be approved by a top-level approver:
|
I've added |
linking openshift/os#498 here as it would avoid this issue |
openshift-hack/images/os/Dockerfile
Outdated
@@ -21,3 +21,5 @@ RUN set -x && yum install -y ostree rpm-ostree yum-utils selinux-policy-targeted | |||
|
|||
FROM scratch | |||
COPY --from=build /srv/ /srv/ | |||
LABEL io.openshift.build.version-display-names="machine-os=Red Hat Enterprise Linux CoreOS (testing)" \ | |||
io.openshift.build.versions="machine-os=1.2.3-testing-machine-os" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
support for SemVer values here, so my string being SemVer means shouldn't break any in-cluster assumptions.
And the fact that it's clearly a dummy/test value will hopefully keep human readers from assuming that the resulting build-for-CI images are official RHCOS releases.
images looks promising: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/origin-ci-test/pr-logs/pull/openshift_kubernetes/963/pull-ci-openshift-kubernetes-master-images/1438569890804928512/artifacts/build-logs/machine-os-content.log | grep machine-os=
2021-09-16T18:56:56.520435642Z STEP 8: LABEL io.openshift.build.version-display-names="machine-os=Red Hat Enterprise Linux CoreOS (testing)" io.openshift.build.versions="machine-os=1.2.3-testing-machine-os" |
e2e-gcp failed on quota, but the release ImageStream looks good: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/origin-ci-test/pr-logs/pull/openshift_kubernetes/963/pull-ci-openshift-kubernetes-master-e2e-gcp/1438569886631596032/artifacts/release/artifacts/release-payload-latest/image-references | jq '.spec.tags[] | select(.name == "machine-os-content").annotations'
{
"io.openshift.build.commit.id": "",
"io.openshift.build.commit.ref": "",
"io.openshift.build.source-location": "",
"io.openshift.build.version-display-names": "machine-os=Red Hat Enterprise Linux CoreOS (testing)",
"io.openshift.build.versions": "machine-os=1.2.3-testing-machine-os"
} |
df59e4c
to
7d4d193
Compare
@wking: the contents of this pull request could not be automatically validated. The following commits could not be validated and must be approved by a top-level approver:
|
7d4d193
to
8814255
Compare
@wking: the contents of this pull request could not be automatically validated. The following commits could not be validated and must be approved by a top-level approver:
|
/lgtm |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
7 similar comments
/retest-required Please review the full test history for this PR and help us cut down flakes. |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
8814255
to
d5e636d
Compare
@wking: the contents of this pull request could not be automatically validated. The following commits could not be validated and must be approved by a top-level approver:
|
openshift-hack/images/os/Dockerfile
Outdated
@@ -21,3 +21,6 @@ RUN set -x && yum install -y ostree rpm-ostree yum-utils selinux-policy-targeted | |||
|
|||
FROM scratch | |||
COPY --from=build /srv/ /srv/ | |||
|
|||
LABEL io.openshift.build.version-display-names="machine-os=rhcos image for testing openshift kubernetes kubelet only. If you see this outside of PR runs for openshift kubernetes- you found an urgent blocker bug" \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
using a -
instead of a ,
to avoid:
...must only be alphanumerics, spaces, and symbols in [():-]
/lgtm |
/retest-required Please review the full test history for this PR and help us cut down flakes. |
…ift.build.versions, etc. For example, consider the current 4.10 RHCOS: $ oc image info -o json registry.ci.openshift.org/ocp/4.10:machine-os-content | jq -r '.config.config.Labels | to_entries[] | .key + ": " + .value' | grep '^io\.k8s\|^io\.openshift' io.k8s.description: The Universal Base Image is designed and engineered to be the base layer for all of your containerized applications, middleware and utilities. This base image is freely redistributable, but Red Hat only supports Red Hat technologies through subscriptions for Red Hat products. This image is maintained by Red Hat and updated regularly. io.k8s.display-name: Red Hat Universal Base Image 8 io.openshift.build.version-display-names: machine-os=Red Hat Enterprise Linux CoreOS io.openshift.build.versions: machine-os=49.84.202109102026-0 io.openshift.expose-services: io.openshift.tags: base rhel8 A bunch of those seem to be inherited from the UBI base image, so we can leave them alone. But the io.openshift.build.* entries are RHCOS-specific, and are consumed by 'oc adm release new ...' [1,2] and friends to answer questions like "which RHCOS is in this release?": $ oc adm release info -o json quay.io/openshift-release-dev/ocp-release:4.8.12-x86_64 | jq .displayVersions { "kubernetes": { "Version": "1.21.1", "DisplayName": "" }, "machine-os": { "Version": "48.84.202109100857-0", "DisplayName": "Red Hat Enterprise Linux CoreOS" } } Setting this label will avoid failures when consumers like driver-toolkit's version consumer [3]: name: 0.0.1-snapshot-machine-os bump into ci-tools-built machine-os-content images that lack the io.openshift.build.versions declaration of machine-os version [4]: error: unable to create a release: unknown version reference "machine-os" I've gone with generic testing values, so hopefully this is not something that local maintainers need to remember to bump for each OpenShift z stream. [1]: https://github.com/openshift/oc/blob/f94afb52dc8a3185b3b9eacaf92ec34d80f8708d/pkg/cli/admin/release/image_mapper.go#L328-L334 [2]: https://github.com/openshift/oc/blob/f94afb52dc8a3185b3b9eacaf92ec34d80f8708d/pkg/cli/admin/release/annotations.go#L19-L28 [3]: openshift/driver-toolkit@464acca#diff-4caed9b2b966a8fa7a016ae28976634a2d3d1b635c4e820d5c038b2305d6af53R18 [4]: https://prow.ci.openshift.org/view/gs/origin-ci-test/pr-logs/pull/openshift_kubernetes/959/pull-ci-openshift-kubernetes-master-images/1438398678602616832#1:build-log.txt%3A97
d5e636d
to
2b79d49
Compare
@wking: the contents of this pull request could not be automatically validated. The following commits could not be validated and must be approved by a top-level approver:
|
/retest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/retest |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cgwalters, deads2k, p0lyn0mial, soltysh, wking 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 |
/cherry-pick release-4.9 |
@dagrayvid: new pull request created: #983 In response to this:
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. |
For example, consider the current 4.10 RHCOS:
A bunch of those seem to be inherited from the UBI base image, so we can leave them alone. But the
io.openshift.build.*
entries are RHCOS-specific, and are consumed byoc adm release new ...
andfriends to answer questions like "which RHCOS is in this release?":
Setting this label will avoid failures when consumers like driver-toolkit's version consumer:
bump into ci-tools-built
machine-os-content
images that lack theio.openshift.build.versions
declaration ofmachine-os
version:I've gone with generic testing values, so hopefully this is not something that local maintainers need to remember to bump for each OpenShift z stream.