|
@@ -1,15 +1,17 @@ |
|
|
--- |
|
|
--- |
|
|
|
|
|
|
|
|
- name: local facts directory |
|
|
|
|
|
|
|
|
- name: ansible local facts directory |
|
|
file: |
|
|
file: |
|
|
path: /etc/ansible/facts.d |
|
|
path: /etc/ansible/facts.d |
|
|
state: directory |
|
|
state: directory |
|
|
|
|
|
|
|
|
- name: local facts |
|
|
|
|
|
|
|
|
- name: set ansible local fact |
|
|
copy: |
|
|
copy: |
|
|
content: "{{ _netdata_local_facts | to_json }}" |
|
|
|
|
|
dest: /etc/ansible/facts.d/netdata.fact |
|
|
|
|
|
|
|
|
content: "{{_local_facts|to_json}}" |
|
|
|
|
|
dest: /etc/ansible/facts.d/{{role_name}}.fact |
|
|
|
|
|
mode: 0600 |
|
|
|
|
|
register: _local_facts_set |
|
|
|
|
|
|
|
|
- name: reread local facts |
|
|
|
|
|
|
|
|
- name: Gathering Facts |
|
|
setup: |
|
|
setup: |
|
|
filter: ansible_local |
|
|
|
|
|
|
|
|
when: _local_facts_set.changed |