Background: This year at Summit, an attendee posed a question about how to work with setting facts and changing data in Ansible. Many times we’ve come across people using task after task to manipulate data, to turn items into lists, filter our options, trying to do heavy data manipulation and to turn data from one source into another.

Ansible Playbooks were never meant for programming.

However after review, it was determined that these data transformations are best done as filters.

For this we used data from the automation controller API, workflows; it gives nested data on the nodes in each workflow to loop around.

Related Articles