Normally I’d add my loop at the end of each task but my playbook is growing rather long. How do I set variables in the playbook so that each task will loop though them ? Something like this
This play is only ran locally. I meant to loop through the customers so that I could have {{ item.customer }} {{ item.archive }} {{ item.bucket }} available as variables in each task in my playbook without having to add the same loop at the end of each task.
Create an inventory in which the 'hosts' are customers and associate
the variables to each host, then have the play run `hosts: customer`
and `delegate_to: localhost`/