---
# Main tasks file for Redis-HA

- name: Gather facts
  ansible.builtin.setup:
    gather_subset: "{{ gfacts_filter }}"

- name: Include precheck task 
  ansible.builtin.include_tasks: precheck.yml
  
- name: Include environment variables
  ansible.builtin.include_vars: "{{ ansENV }}/env_{{ ansENV }}.yml"
  
- name: Include build task if option is "build"
  ansible.builtin.include_tasks: build.yml
  when: ansAction == "build"
  
- name: Include undeploy task if option is "undeploy"
  ansible.builtin.include_tasks: undeploy.yml
  when: ansAction == "undeploy"
  
- name: Include deploy task if option is "deploy"
  ansible.builtin.include_tasks: deploy.yml
  when: ansAction == "deploy"
  
