observability/roles/cadvisor/tasks/main.yml

19 lines
675 B
YAML
Raw Normal View History

---
- name: Ensure state is valid
ansible.builtin.fail:
msg: >-2
Unknown state '{{ cadvisor_state }}'! Supported
states are: {{ cadvisor_states | join(', ') }}.
when: cadvisor_state not in cadvisor_states
- name: Ensure deployment method is valid
ansible.builtin.fail:
msg: >-2
Unknown deployment method '{{ cadvisor_deployment_method }}'! Supported
deployment methods are: {{ cadvisor_deployment_methods | join(', ') }}.
when: cadvisor_deployment_method not in cadvisor_deployment_methods
- name: Deploy using {{ cadvisor_deployment_method }}
ansible.builtin.include_tasks:
file: "deploy-{{ cadvisor_deployment_method }}.yml"