mirror of
https://github.com/ansible/awx.git
synced 2026-05-20 07:17:40 -02:30
support fact caching for isolated hosts
see: https://github.com/ansible/awx/issues/198
This commit is contained in:
@@ -25,3 +25,14 @@
|
||||
fail:
|
||||
msg: "isolated task is still running"
|
||||
when: "is_alive.rc == 0"
|
||||
|
||||
- stat: path="{{src}}/facts/"
|
||||
register: fact_cache
|
||||
|
||||
- name: Copy gathered facts from the isolated host.
|
||||
synchronize:
|
||||
src: "{{src}}/facts/"
|
||||
dest: "{{src}}/facts/"
|
||||
delete: yes # delete fact cache records that go missing via clear_facts
|
||||
mode: pull
|
||||
when: fact_cache.stat.exists
|
||||
|
||||
Reference in New Issue
Block a user