---
- name: Read in CSV contents
  read_csv    :
    path      : "{{ playbook_dir }}/files/{{ __csv_file }}"
  register    : r_csv_inventory
  delegate_to : localhost


- name: Write inventory from CSV data
  template:
    src  : templates/csv_static_inventory.j2
    dest : "{{ playbook_dir }}/files/csv_static_inventory.ini"


...
