kolla-ansible/ansible/roles/manila/tasks/check-containers.yml
LinPeiWen 43e89ddab3 Use Docker healthchecks for manila services
This change enables the use of Docker healthchecks for manila services.
Implements: blueprint container-health-check

Change-Id: I3a2239764b7e3d6db51e535404388a512aba7629
2021-02-03 06:28:52 +00:00

19 lines
648 B
YAML

---
- name: Check manila containers
become: true
kolla_docker:
action: "compare_container"
common_options: "{{ docker_common_options }}"
name: "{{ item.value.container_name }}"
image: "{{ item.value.image }}"
privileged: "{{ item.value.privileged|default(False) }}"
volumes: "{{ item.value.volumes|reject('equalto', '')|list }}"
dimensions: "{{ item.value.dimensions }}"
healthcheck: "{{ item.value.healthcheck | default(omit) }}"
when:
- inventory_hostname in groups[item.value.group]
- item.value.enabled | bool
with_dict: "{{ manila_services }}"
notify:
- "Restart {{ item.key }} container"