Hi,

Given the following structure:

roles/bugzilla/vars/main.yml:

bugzilla:
  vhost:
    name: x
    stuff: c

roles/subversion/vars/main.yml:
    
subversion:
  vhost:
   name: y
    stuff: d

I'm trying to do the following

playbook.yml:

- name: x
  ...
   roles:
     - { role: apache, vhosts: [ 'subversion', 'bugzilla' ] }

roles/apache/tasks/main.yml:

- name: render vhosts
  template: 
     src: {{ item['vhost']['name'] }}.conf
     ..
   with_items:
      - vhosts

I would expect that the with_items loops evaluated 'vhosts' to subversion 
and bugzilla and in term give me access to the underlying structure of 
those variables, thus bugzilla.vhost.name etc. however I can't seem to get 
this to work.
What am I doing wrong here? Or is this simply not supported?

Thanks,
Nico

-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/bbbb0518-84d2-411e-bc76-1dc1a6f481fe%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to