Files
ansible_role_package/tasks/pkgs/consul.yml
2025-03-03 12:04:09 -07:00

32 lines
770 B
YAML

# vim: set filetype=yaml.ansible :
---
- name: Add consul
when:
- consul_configured is undefined
block:
- name: Load consul config
ansible.builtin.include_tasks:
file: config/consul.yml
- name: Append to pkg_sys
when:
- ansible_system == 'Linux'
notify:
- Depend hashicorp repo
changed_when: true
ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + consul.pkgs }}"
- name: Append to pkg_tap
when:
- ansible_system == 'Darwin'
notify:
- Depend hashicorp repo
changed_when: true
ansible.builtin.set_fact:
pkg_tap: "{{ pkg_tap + consul.pkgs }}"
- name: Set consul_configured
ansible.builtin.set_fact:
consul_configured: true