mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
Starting to move over lookups and fixing some bugs related to that
This commit is contained in:
11
v2/samples/with_items.yml
Normal file
11
v2/samples/with_items.yml
Normal file
@@ -0,0 +1,11 @@
|
||||
- hosts: localhost
|
||||
connection: local
|
||||
vars:
|
||||
my_list:
|
||||
- a
|
||||
- b
|
||||
- c
|
||||
gather_facts: no
|
||||
tasks:
|
||||
- debug: msg="item is {{item}}"
|
||||
with_items: my_list
|
||||
13
v2/samples/with_nested.yml
Normal file
13
v2/samples/with_nested.yml
Normal file
@@ -0,0 +1,13 @@
|
||||
- hosts: localhost
|
||||
connection: local
|
||||
gather_facts: no
|
||||
vars:
|
||||
users:
|
||||
- foo
|
||||
- bar
|
||||
- bam
|
||||
tasks:
|
||||
- debug: msg="item.0={{ item[0] }} item.1={{ item[1] }}"
|
||||
with_nested:
|
||||
- users
|
||||
- [ 'clientdb', 'employeedb', 'providerdb' ]
|
||||
Reference in New Issue
Block a user