2016-07-08 13:34:04 -03:00
|
|
|
---
|
|
|
|
- name: Ensuring config directories exist
|
|
|
|
file:
|
2018-05-18 14:09:45 +00:00
|
|
|
path: "{{ node_config_directory }}/{{ item.key }}"
|
2016-07-08 13:34:04 -03:00
|
|
|
state: "directory"
|
2016-08-24 00:28:08 +07:00
|
|
|
owner: "{{ config_owner_user }}"
|
|
|
|
group: "{{ config_owner_group }}"
|
|
|
|
mode: "0770"
|
|
|
|
become: true
|
2018-05-18 14:09:45 +00:00
|
|
|
when:
|
|
|
|
- inventory_hostname in groups[item.value.group]
|
|
|
|
- item.value.enabled | bool
|
|
|
|
with_dict: "{{ multipathd_services }}"
|
2016-07-08 13:34:04 -03:00
|
|
|
|
|
|
|
- name: Copying over config.json files for services
|
|
|
|
template:
|
2018-05-18 14:09:45 +00:00
|
|
|
src: "{{ item.key }}.json.j2"
|
|
|
|
dest: "{{ node_config_directory }}/{{ item.key }}/config.json"
|
2016-08-24 00:28:08 +07:00
|
|
|
mode: "0660"
|
|
|
|
become: true
|
2018-05-18 14:09:45 +00:00
|
|
|
when:
|
|
|
|
- inventory_hostname in groups[item.value.group]
|
|
|
|
- item.value.enabled | bool
|
|
|
|
with_dict: "{{ multipathd_services }}"
|
|
|
|
notify:
|
|
|
|
- Restart multipathd container
|
2016-07-08 13:34:04 -03:00
|
|
|
|
|
|
|
- name: Copying over multipath.conf
|
|
|
|
template:
|
2018-05-18 14:09:45 +00:00
|
|
|
src: "multipath.conf.j2"
|
|
|
|
dest: "{{ node_config_directory }}/{{ item.key }}/multipath.conf"
|
2016-08-24 00:28:08 +07:00
|
|
|
mode: "0660"
|
|
|
|
become: true
|
2018-05-18 14:09:45 +00:00
|
|
|
when:
|
|
|
|
- inventory_hostname in groups[item.value.group]
|
|
|
|
- item.value.enabled | bool
|
|
|
|
with_dict: "{{ multipathd_services }}"
|
|
|
|
notify:
|
|
|
|
- Restart multipathd container
|