browbeat/ansible/gather/roles/neutron/tasks/main.yml

24 lines
571 B
YAML

---
#
# Tasks to get neutron facts
#
- name: Check that Neutron is installed
become: true
stat: path=/etc/neutron/neutron.conf
register: neutron_config
- name: Parse Neutron config
become: true
shell: python /tmp/openstack-config-parser.py neutron /tmp/out.yml
when: neutron_config.stat.exists
- name: Fetch output
fetch: src=/tmp/out.yml dest=/tmp/out-{{ inventory_hostname }}.yml flat=yes
when: neutron_config.stat.exists
- name: Load configuration variables
include_vars: /tmp/out-{{ inventory_hostname }}.yml
when: neutron_config.stat.exists