Say I have two variable like these:
var1:
key1: val1
key2: val2
var2:
- item1
- item2
Can I loop over these two variables like below?
- shell: echo {{ item.0.value }} {{ item.1 }}
with_dict: "{{ var1 }}"
with_items: "{{ var2 }}"
I have no idea to loop over these two variables together and don’t wanna change the data type of the variables. Is there any way to achieve this kind of loop in ansible?