-
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
The events API is not Docker-compatible when using the same filter multiple times #10507
Comments
Thanks for opening the issue! We need to fix it in |
Thank you @vrothberg for the detailed response! I'd be happy to contribute a fix in the coming weeks. |
Thanks, @ahmed-mez! I will try to tackle it today. We are close to a release, and it would be good to have a fix for it in. |
Sounds great, thank you! |
I opened #10514 to fix the issue. |
While different filters are applied in conjunction, the same filter (but with different values) should be applied in disjunction. This allows, for instance, to query the events of two containers. Fixes: containers#10507 Signed-off-by: Valentin Rothberg <[email protected]>
While different filters are applied in conjunction, the same filter (but with different values) should be applied in disjunction. This allows, for instance, to query the events of two containers. Fixes: containers#10507 Backport-of: commit 37f39ee Signed-off-by: Valentin Rothberg <[email protected]>
hey @vrothberg , thank you for fixing this! I thought |
Thanks for reaching out. It should land in Kubic soon (Cc @lsm5). -rc3 did not include the fix yet. |
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
Podman's events API doesn't handle the case where the same filter is used multiple times like Docker does.
Docker documentation: https://docs.docker.com/engine/reference/commandline/events/
However, Podman will still apply an AND instead of an OR for the example above.
Steps to reproduce the issue:
podman events --since 5m --filter "container=1c62ec17cb44" 2021-05-31 09:36:09.923083952 +0000 UTC container create 1c62ec17cb44e183f83db5261551bd0d5c0db75e0973e8bbf32c97e41b5700a1 (image=docker.io/library/redis:latest, name=gracious_khorana) 2021-05-31 09:36:10.200379849 +0000 UTC container init 1c62ec17cb44e183f83db5261551bd0d5c0db75e0973e8bbf32c97e41b5700a1 (image=docker.io/library/redis:latest, name=gracious_khorana) 2021-05-31 09:36:10.212573077 +0000 UTC container start 1c62ec17cb44e183f83db5261551bd0d5c0db75e0973e8bbf32c97e41b5700a1 (image=docker.io/library/redis:latest, name=gracious_khorana)
Describe the results you received:
Using the
container
filter more than once hasn't been considered as an OR.Describe the results you expected:
Same behaviour as Docker: Using the same filter multiple times will be handled as a OR.
Additional information you deem important (e.g. issue happens only occasionally):
Output of
podman version
:Output of
podman info --debug
:Package info (e.g. output of
rpm -q podman
orapt list podman
):Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide? (https://github.com/containers/podman/blob/master/troubleshooting.md)
Yes
Additional environment details (AWS, VirtualBox, physical, etc.):
VirtualBox
The text was updated successfully, but these errors were encountered: