是否有可能在一個with_items
循環使用with_first_found
如:ansible 1.6>在with_items循環中使用with_first_found?
- template:
dest=/foo/{{ item.name }}-{{ item.branch | default('master') }}
src={{ item }}
with_first_found:
- {{ item.name }}-{{ item.branch | default('master') }}
- {{ item.name }}.j2
- apache_site.j2
with_items: apache_sites
似乎無法使其工作使用with_nested
。
看起來毛茸茸的,什麼是你想實現什麼? – Rico