blob: a17767586bda4af61c636f7570622ace2e8e3710 [file] [log] [blame]
{%- from "cinder/map.jinja" import controller,volume with context %}
{%- if controller.enabled %}
{%- set _data = controller %}
{%- set type = 'controller' %}
{%- elif volume.enabled %}
{%- set _data = volume %}
{%- set type = 'volume' %}
{%- endif %}
/etc/cinder/cinder.conf:
file.managed:
- source: salt://cinder/files/{{ _data.version }}/cinder.conf.{{ type }}.{{ grains.os_family }}
- template: jinja
{%- if _data.get('concurrency', {}).lock_path is defined %}
cinder_upgrade_{{ type }}_lock_path_{{ _data.concurrency.lock_path }}:
file.directory:
- name: {{ _data.concurrency.lock_path }}
- user: cinder
- group: cinder
- mode: 750
- makedirs: True
{%- endif %}