Add extra conf for cinder and ceph

This commit is contained in:
Kevin TIBI 2018-01-11 16:47:52 +01:00
parent 7846d4ecca
commit 2fafff1d68
6 changed files with 47 additions and 0 deletions

View File

@ -96,6 +96,8 @@
mime: False
register: stat_result
with_items:
- { name: ceph, file: ceph.conf }
- { name: cinder, file: cinder.conf }
- { name: glance, file: glance.conf }
- { name: heat, file: heat.conf }
- { name: inspector, file: ironic-inspector.conf }
@ -192,6 +194,8 @@
kolla_inspector_dhcp_pool_end: "{{ inspection_net_name | net_inspection_allocation_pool_end }}"
kolla_inspector_default_gateway: "{{ inspection_net_name | net_inspection_gateway or inspection_net_name | net_gateway }}"
# Extra free-form user-provided configuration.
kolla_extra_ceph: "{{ kolla_extra_config.ceph | default }}"
kolla_extra_cinder: "{{ kolla_extra_config.cinder | default }}"
kolla_extra_glance: "{{ kolla_extra_config.glance | default }}"
kolla_extra_heat: "{{ kolla_extra_config.heat | default }}"
kolla_extra_inspector: "{{ kolla_extra_config.inspector | default }}"

View File

@ -5,6 +5,24 @@ kolla_extra_config_path:
# Directory where Kolla custom configuration files will be installed.
kolla_node_custom_config_path:
###############################################################################
# ceph configuration.
# Whether to enable ceph.
kolla_enable_ceph:
# Free form extra configuration to append to ceph.conf.
kolla_extra_ceph:
###############################################################################
# cinder configuration.
# Whether to enable cinder.
kolla_enable_cinder:
# Free form extra configuration to append to cinder.conf.
kolla_extra_cinder:
###############################################################################
# Glance configuration.

View File

@ -13,6 +13,8 @@
dest: "{{ kolla_node_custom_config_path }}/{{ item.dest }}"
mode: 0640
with_items:
- { src: ceph.conf.j2, dest: ceph.conf, enabled: "{{ kolla_enable_ceph }}" }
- { src: cinder.conf.j2, dest: cinder.conf, enabled: "{{ kolla_enable_cinder }}" }
- { src: glance.conf.j2, dest: glance.conf, enabled: "{{ kolla_enable_glance }}" }
- { src: heat.conf.j2, dest: heat.conf, enabled: "{{ kolla_enable_heat }}" }
- { src: ironic.conf.j2, dest: ironic.conf, enabled: "{{ kolla_enable_ironic }}" }

View File

@ -0,0 +1,9 @@
# {{ ansible_managed }}
{% if kolla_extra_ceph %}
#######################
# Extra configuration
#######################
{{ kolla_extra_ceph }}
{% endif %}

View File

@ -0,0 +1,9 @@
# {{ ansible_managed }}
{% if kolla_extra_cinder %}
#######################
# Extra configuration
#######################
{{ kolla_extra_cinder }}
{% endif %}

View File

@ -14,6 +14,11 @@ kolla_openstack_custom_config:
dest: "{{ kolla_node_custom_config_path }}/ceph"
patterns: "*"
enabled: "{{ kolla_enable_ceph }}"
# Cinder.
- src: "{{ kolla_extra_config_path }}/cinder"
dest: "{{ kolla_node_custom_config_path }}/cinder"
patterns: "*"
enabled: "{{ kolla_enable_cinder }}"
# Fluentd filters.
- src: "{{ kolla_extra_config_path }}//fluentd/filter"
dest: "{{ kolla_node_custom_config_path }}/fluentd/filter"