-
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
restartPolicy doesn't seem to work with podman play kube
#7656
Comments
Sorry. My brain tricked me to mix "restart" and "pull" policy. The issues are different, so I am going to reopen :) In the meantime, I'll grab a fresh coffee. |
have you try the latest version, such as |
Just tried this:
Same problem, container failed, but was not restarted:
|
P.S. You might consider clarifying you issue-template a bit, because |
Just to add some more context to it: my container fails at the first attempt of the initialization. But if, in a couple of seconds, I manually do the |
To verify the policy is not being set correctly, can you provide the output of |
|
I don't see us dealing with this in the Yaml files at all. |
@ashley-cui PTAL if no one in the community looks into it. |
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
I'd like to achieve the behavior when failed containers (exited with non-zero exit code) are automatically restarted by Podman in a deployment run by
podman play kube
. AFAIK, the default option isalways
(if nothing else is explicitly specified). However, when my container dies (Exited (1) 10 minutes ago
), it doesn't get automatically restarted. I tried explicitly addingalways
option:restartPolicy: Always
, but it changed nothing, exited container remains exited without any visible attempts to restart it.Steps to reproduce the issue:
Create a Kubernetes file with a pod having a container that fails upon the start.
podman play kube
Describe the results you received:
Container fails and doesn't get restarted.
Describe the results you expected:
Podman tries to restart the exited container.
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?
Yes
Additional environment details (AWS, VirtualBox, physical, etc.):
CentOS 8 VM
The text was updated successfully, but these errors were encountered: