Hi, 

I've got a usecase where I'd like to iterate over several servers based on 
groups, so task looks like:

- name: group A & B
  shell: echo {{ item }} >> /tmp/log
  with_items:
  - groups["A"]
  - groups["B"]

so what I get in /tmp/log is:

groups['A']
groups['B']

Now, eliminating either group I can get:

- name: group A
  shell: echo {{ item }} >> /tmp/log
  with_items: groups["A"]
 
I get proper result. 

I'm pretty certain I've seen this topic come up recently but can't find it 
anymore. Any pointers (including links to other topics) are welcome.

P.S.
for bonus points - can I do set-like concatenation - i.e. eliminate 
duplicates? 

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/9c508e6f-3d70-4c6d-a357-330e1eabfd18%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to