Commit 00e2129d authored by nanahira's avatar nanahira

use loop

parent 1d06f09e
...@@ -99,13 +99,13 @@ ...@@ -99,13 +99,13 @@
include_tasks: 'protocols/{{item.protocol}}/configure.yaml' include_tasks: 'protocols/{{item.protocol}}/configure.yaml'
vars: vars:
conn: '{{item}}' conn: '{{item}}'
with_items: '{{ connections }}' loop: '{{ connections }}'
when: "not noUpdateLinks and item.protocol is defined and item.protocol == 'null' and not item.noUpdate" when: "not noUpdateLinks and item.protocol is defined and item.protocol == 'null' and not item.noUpdate"
- name: 'loop through list from a variable' - name: 'loop through list from a variable'
include_tasks: 'protocols/{{item.protocol}}/configure.yaml' include_tasks: 'protocols/{{item.protocol}}/configure.yaml'
vars: vars:
conn: '{{item}}' conn: '{{item}}'
with_items: '{{ connections }}' loop: '{{ connections }}'
when: "not noUpdateLinks and item.protocol is defined and item.protocol != 'null' and not item.noUpdate" when: "not noUpdateLinks and item.protocol is defined and item.protocol != 'null' and not item.noUpdate"
# end # end
- name: services conf - name: services conf
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment