-
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
More flexible options when combining '--rm' and '--restart' #7906
Comments
about the value, you cloud see https://github.com/containers/podman/blob/master/test/e2e/run_test.go#L70-L91
|
Sorry, I'm still not understanding:
... is Ah, but I think I see what you mean - I was assuming that if In which case, it very much seems to be an 'or' situation... how about:
... or similar? Why, though, can we not have
... so ideally, The documentation already says:
... so could the behaviour not be amended so that another exception is that it doesn't remove a container with a restartPolicy of 'on-failure' unless it has cleanly stopped without failing? Additionally, the documentation doesn't seem to mention that It does say, though:
... which still leads me to feel that it should be possible to use |
could see this condition if c.Rm && c.Restart != "" && c.Restart != "no" {
return errors.Errorf(`the --rm option conflicts with --restart, when the restartPolicy is not "" and "no"`)
}
|
To clarify, this issue is open to suggest that '
The latter shouldn't block the former. |
A friendly reminder that this issue had no activity for 30 days. |
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
With
podman-2.1.1
with patch #7895 , running a container with--rm
and--restart on-failure
results in the output:So a couple of things:
Should there be a value within the first set if quotes? Should the final 'and' read 'or'?
Surely if should be possible to combine
--rm
and--restart on-failure
(specifically) - the idea being that the container would be removed when externally killed by viapodman stop
(or equivalent), but would be restarted if the container's PID 1 aborts for any other internally-triggered reason (and/or results in a non-zero exit code)?Output of
podman version
:Output of
podman info --debug
:Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide?
Yes
The text was updated successfully, but these errors were encountered: