Closed idelsink closed 5 months ago
Thanks for reporting this. Can you please elaborate - what is the use case of setting healthcheck command to none
?
Beside it being a feature of podman itself, (see here) I wanted to disable the healtcheck for one of my containers because it was causing a lot of log messages with the contents of container exec_died ...
that comes from the healtcheck.
This is somewhat related to this issue where someone also asked for a log level feature: https://github.com/containers/podman/issues/17856.
An example of the amount of logging that gets aggregated is here (left before I disabled the healtcheck and right after I set it to none)
So for me why I'm disableing this is I don't need that healtcheck (I have my own monitoring) and to reduce disk IO. But honestly I don't think my reasoning should be entirety relevant, surly someone at some point has a better reason to use this feature and I think it's nice if that is supported (with it being an intended feature after all :smile: )
@idelsink #745 should fix all for you. Please feel free to reopen if it still has an issue or you discover a new one.
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
When the healtcheck is of a container is set to the value
none
, the container keeps being recreated instead of it being created only once.Steps to reproduce the issue:
podman-demo.yml
playbook (contents pasted below).Describe the results you received:
A new container will be created (changed) by the first task. The second task will recreate the container (changed) despite having the exact same configuration. If the --diff option is provided Ansible will show that the healtcheck was empty instead of "none", hence the reason the container keeps being recreated.
Describe the results you expected:
The first task should create the container if it doesn't exist (changed). The second task should properly compare the running container with the requested properties and do nothing (ok).
Additional information you deem important (e.g. issue happens only occasionally):
There is also a
--no-healthcheck
option for podman, but this collection does not yet seem to support that. I could potentially make a new feature request to add that.Version of the
containers.podman
collection: Either git commit if installed from git:git show --summary
Or version fromansible-galaxy
if installed from galaxy:ansible-galaxy collection list | grep containers.podman
Output of
ansible --version
:Output of
podman version
:Output of
podman info --debug
:Package info (e.g. output of
rpm -q podman
orapt list podman
):Playbok you run with ansible (e.g. content of
playbook.yaml
):Command line and output of ansible run with high verbosity
Please NOTE: if you submit a bug about idempotency, run the playbook with
--diff
option, like:ansible-playbook podman-demo.yml --diff -vv
Additional environment details (AWS, VirtualBox, physical, etc.):