fcf755c8ce
Change-Id: Ice5b058fe17ad7d648f21d1ddacaa339c6f7102f
52 lines
1.4 KiB
YAML
52 lines
1.4 KiB
YAML
---
|
|
- name: Ensuring config directory exists
|
|
file:
|
|
path: "{{ node_config_directory }}/{{ item }}"
|
|
state: "directory"
|
|
when: inventory_hostname in groups[item]
|
|
with_items:
|
|
- "gnocchi-api"
|
|
- "gnocchi-metricd"
|
|
- "gnocchi-statsd"
|
|
|
|
- name: Copy over ceph.conf file
|
|
template:
|
|
src: "{{ node_custom_config }}/{{ item }}/ceph.conf"
|
|
dest: "{{ node_config_directory }}/{{ item }}/ceph.conf"
|
|
when: inventory_hostname in groups[item]
|
|
with_items:
|
|
- "gnocchi-api"
|
|
- "gnocchi-metricd"
|
|
- "gnocchi-statsd"
|
|
notify:
|
|
- Restart gnocchi-api container
|
|
- Restart gnocchi-metricd container
|
|
- Restart gnocchi-statsd container
|
|
|
|
- name: Copy over ceph gnocchi keyring
|
|
copy:
|
|
src: "{{ node_custom_config }}/{{ item }}/ceph.client.gnocchi.keyring"
|
|
dest: "{{ node_config_directory }}/{{ item }}/ceph.client.gnocchi.keyring"
|
|
when: inventory_hostname in groups[item]
|
|
with_items:
|
|
- "gnocchi-api"
|
|
- "gnocchi-metricd"
|
|
- "gnocchi-statsd"
|
|
notify:
|
|
- Restart gnocchi-api container
|
|
- Restart gnocchi-metricd container
|
|
- Restart gnocchi-statsd container
|
|
|
|
- name: Ensuring config directory has correct owner and permission
|
|
become: true
|
|
file:
|
|
path: "{{ node_config_directory }}/{{ item }}"
|
|
recurse: yes
|
|
owner: "{{ config_owner_user }}"
|
|
group: "{{ config_owner_group }}"
|
|
when: inventory_hostname in groups[item]
|
|
with_items:
|
|
- "gnocchi-api"
|
|
- "gnocchi-metricd"
|
|
- "gnocchi-statsd"
|