diff options
author | Felix Fontein <felix@fontein.de> | 2020-02-03 19:13:17 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-03 13:13:17 -0500 |
commit | 5c1a3a3ac2086119bd16316dde379047d90cd86c (patch) | |
tree | e4e89484171b645f7e5a1e046b9d294a55a5df49 /lib/ansible/modules/cloud/docker/docker_container.py | |
parent | d6f2b4e788ed13756ba4e4a05b8b7a879900dbc3 (diff) | |
download | ansible-5c1a3a3ac2086119bd16316dde379047d90cd86c.tar.gz |
docker_container and docker_swarm_service: allow to actually disable healthcheck of image (#66599)
* Allow to actually disable healthcheck of image.
* Add changelog.
Diffstat (limited to 'lib/ansible/modules/cloud/docker/docker_container.py')
-rw-r--r-- | lib/ansible/modules/cloud/docker/docker_container.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/ansible/modules/cloud/docker/docker_container.py b/lib/ansible/modules/cloud/docker/docker_container.py index 24856e8aa5..2c8c7df85d 100644 --- a/lib/ansible/modules/cloud/docker/docker_container.py +++ b/lib/ansible/modules/cloud/docker/docker_container.py @@ -1480,6 +1480,10 @@ class TaskParameters(DockerBaseClass): if self.client.option_minimal_versions[value]['supported']: result[key] = getattr(self, value) + if self.disable_healthcheck: + # Make sure image's health check is overridden + result['healthcheck'] = {'test': ['NONE']} + if self.networks_cli_compatible and self.networks: network = self.networks[0] params = dict() |