24 lines
523 B
YAML
24 lines
523 B
YAML
|
---
|
||
|
- name: create local facts directory
|
||
|
file:
|
||
|
dest: /etc/ansible/facts.d
|
||
|
state: directory
|
||
|
recurse: yes
|
||
|
|
||
|
- name: install local facts
|
||
|
template:
|
||
|
src: "etc/ansible/facts.d/{{ item }}.fact.j2"
|
||
|
dest: "/etc/ansible/facts.d/{{ item }}.fact"
|
||
|
mode: 0755
|
||
|
register: installed_facts
|
||
|
loop: "{{ custom_facts }}"
|
||
|
|
||
|
- name: regather all facts
|
||
|
setup:
|
||
|
gather_subset: "all,local"
|
||
|
when: installed_facts.changed
|
||
|
|
||
|
- name: set moe_release fact
|
||
|
set_fact:
|
||
|
moe_release: "{{ ansible_local.moe_release }}"
|