23 lines
576 B
YAML
23 lines
576 B
YAML
---
|
|
#
|
|
# Tasks to get gnocchi config data
|
|
#
|
|
|
|
- name: Check that Gnocchi is installed
|
|
become: true
|
|
stat: path=/etc/gnocchi/gnocchi.conf
|
|
register: gnocchi_config
|
|
|
|
- name: Parse Gnocchi config
|
|
become: true
|
|
shell: python /tmp/openstack-config-parser.py gnocchi /tmp/out.yml
|
|
when: gnocchi_config.stat.exists
|
|
|
|
- name: Fetch output
|
|
fetch: src=/tmp/out.yml dest=/tmp/out-{{ inventory_hostname }}.yml flat=yes
|
|
when: gnocchi_config.stat.exists
|
|
|
|
- name: Load configuration variables
|
|
include_vars: /tmp/out-{{ inventory_hostname }}.yml
|
|
when: gnocchi_config.stat.exists
|