-
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
Exit codes #521
base: main
Are you sure you want to change the base?
Exit codes #521
Conversation
Signed-off-by: Benjamin Karran <[email protected]>
Signed-off-by: Benjamin Karran <[email protected]>
@ebekebe looks like other commands (like |
@mi-volodin I didn't notice that other commands also don't work. I would have included them at the time. However, we don't use podman-compose (and podman) anymore, because of how it is maintained. As there is no feedback from a project maintainer yet, I don't want to put any more effort into this. Feel free to make your own PR or add you changes to this PR. Let me know, if you want push access. |
sad to see an unmaintainable repo |
Seems like the issue fixed by this PR is still present at least for some commands. @ebekebe Would you be open to rebase the PR? |
@@ -1863,7 +1863,9 @@ def compose_push(compose, args): | |||
continue | |||
if services and cnt["_service"] not in services: | |||
continue | |||
compose.podman.run([], "push", [cnt["image"]], sleep=0) | |||
exit_code = compose.podman.run([], "push", [cnt["image"]], sleep=0).wait() | |||
if (not getattr(args, "ignore_push_failures", None)) and 0 != exit_code: |
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.
Why can't we do args.ignore_push_failures
? Seems simplier.
Also, please use exit_code != 0
style.
Failure exit codes for
build
andpush
are currently not forwarded as exit code for podman-compose. This makes it impossible to use podman-compose in a scripted environment like CI.With this PR, podman-compose stops building/pushing when the underlying podman command fails and forwards its exit code.