In your second example, you could do this:

path: "{{ ['righthere'] | union(level1keyB) }}"


I'm not sure it's possible in your first example, because to put this in 
your "WHAT TO WRITE HERE" section you have to access "addonpath" from 
another part of the same level1keyA data structure, so you end up with a 
recursive loop error.


On Wednesday, 30 March 2016 15:00:05 UTC+1, Jard Leex wrote:
>
> To make my request a bit more clear:
>
>
> I'd like to have the entries of *level1keyB* in the path list of the 
> hostname bar. The key 'addonpath' is just an guessed construct by me. Maybe 
> this would also work.
>
>
> - level1keyA:
>         - hostname: foo
>           state: present
>           path:
>             - left
>         - hostname: bar
>           state: present
>           path:
>             - righthere
>             - "{{ entries of level1keyB }}"
>
> But how to do it in practise?
>
> Thank you.
>
>

-- 
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/f2447b68-a7b8-4b0a-85f1-462ff233aba2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to