I have vars defined like this:
x_named_zones:
- name: 'example1.com'
type: 'dynamic'
- name: 'example2.org'
type: 'dynamic'
- name: 'example3.tld'
type: 'master'
and I would like to iterate over them with a task:
- name: loop over the list
debug:
msg: 'name: {{ item.name }} type: {{ item.type }}'
loop: '{{ x_named_zones }}'
and this works. But how can I loop over the list where the type: dynamic only? So the expected result of the loop task would be:
example1.com and example2.org