-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Kube Play - set ReportWriter when building an image #20889
Kube Play - set ReportWriter when building an image #20889
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ygalblum 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 |
7e93afe
to
e7695b8
Compare
The CI is failing because the play build tests expect a clean output while following this change, the output includes lines about the pulling of the image. |
I am in favor of changing the tests. The build output is important to have IMO. @rhatdan PTAL |
Yes lets fix the test. Opts output is to stderr so can we segment based on this. Haven't looked but in BATS I know this is difficult. if not impossible. |
Thanks. I was thinking about setting |
e7695b8
to
2b2cc8c
Compare
LGTM |
2b2cc8c
to
2ae61ca
Compare
2ae61ca
to
0534a80
Compare
test/system/252-quadlet.bats
Outdated
is "$output" "running" "container should be started by systemd and hence be running" | ||
|
||
service_cleanup $QUADLET_SERVICE_NAME inactive | ||
run_podman rmi $(pause_image) |
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.
Nasty red. Suggestion:
@@ -1480,2 +1480,3 @@ EOF
+ local untagged_image=quay.io/libpod/busybox
local image_name=test_image
@@ -1489,3 +1490,3 @@ EOF
cat >$container_file_path << EOF
-FROM busybox
+FROM $untagged_image
EOF
@@ -1533,3 +1534,3 @@ EOF
service_cleanup $QUADLET_SERVICE_NAME inactive
- run_podman rmi $(pause_image)
+ run_podman rmi $untagged_image $image_name $(pause_image)
}
(secondary, low-priority suggestion: rename variable image_name
to built_image
)
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.
Done (both), thanks
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.
Well, partly: $untagged_image
is undefined, so there's still red. You can either take the other half of my suggestion above, or s/$untagged_image/busybox/
. My reason for suggesting $untagged_image
and setting it to a repo+image (untagged) is to prevent docker.io
rate limiting on hosts like Fedora CI where they might not have our registries.conf
overrides. I would like to prevent Fedora Gating flakes.
Obviously I tested quay.io/libpod/busybox
on my end, using your PR as well as main
(where the test fails with the expected crash) but if you go that route please confirm.
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.
I've taken in all your comments including using quay.io/libpod/busybox
. I also make sure that the image is not available on the local machine before running the test. I ran the test locally and it did not prompt about any stray images. So, hopefully, it's OK now.
BTW initially, I wanted to use a local registry instead of downloading a new image. However, building an image based on a private registry using kube play
is not fully supported (See #20890 for details)
Anyhow, thanks a lot for your help (here and in general)
0534a80
to
66af520
Compare
Add test for a specific crash Update play build test to expect message in stderr Signed-off-by: Ygal Blum <[email protected]>
66af520
to
a943be7
Compare
/lgtm |
@Luap99 @mheon @ashley-cui are we ok backporting this to v4.8 for v4.8.2? |
Looks like a bug fix so no objection from my side. |
/cherry-pick v4.8 |
@lsm5: #20889 failed to apply on top of branch "v4.8":
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. |
Add test for a specific crash
Does this PR introduce a user-facing change?
No
Resolves: #20432