-
Notifications
You must be signed in to change notification settings - Fork 485
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
Support all healthcheck options in Compose #780
base: main
Are you sure you want to change the base?
Conversation
recursiveribbons
commented
Sep 24, 2023
- Added start_interval to the healthcheck block parser
- Changed the healthcheck flags to the normalized podman flags
ddfb28a
to
8510983
Compare
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.
Thanks for the PR. It looks good.
Please add unit tests. See e.g. pytests/test_container_to_args.py for an example.
8510983
to
ae6e67f
Compare
(rebased branch onto main and force pushed) |
338f44b
to
34de89f
Compare
Signed-off-by: Robin Syl <[email protected]>
Signed-off-by: Robin Syl <[email protected]>
Signed-off-by: Robin Syl <[email protected]>
34de89f
to
efccf15
Compare
I'm not sure how to fix the unit test, as |
Signed-off-by: Robin Syl <[email protected]>
65072f7
to
f512566
Compare
Do you actually want me to commit the entire formatted podman_compose.py file or just let the test fail? also the pre-commit checks wants me to format 10 files so I'm not sure if I should |
@@ -1032,12 +1029,12 @@ async def container_to_args(compose, cnt, detached=True): | |||
podman_args.append("--no-healthcheck") | |||
elif healthcheck_type == "CMD": | |||
cmd_q = "' '".join([cmd_quote(i) for i in healthcheck_test]) | |||
podman_args.extend(["--healthcheck-command", "/bin/sh -c " + cmd_q]) | |||
podman_args.extend(["--health-cmd", "/bin/sh -c " + cmd_q]) |
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 don't think in CMD
case this should be executed with /bin/sh
prevents cases from working where there is no /bin/sh
in the image like minimal images for Rust applications. I don't have docker to verify, but from the documentation, my understanding is that this is ran without shell.