Added possibility define OPENSTACK_CINDER_FEATURES parameter
A dictionary of settings which can be used to enable optional services provided by cinder. Currently only the backup service is available.
Change-Id: I09cfbc65e29d1cdc8ebf82c939705525093cf5ca
Related-PROD: PROD-22313
diff --git a/horizon/files/horizon_settings/_cinder_settings.py b/horizon/files/horizon_settings/_cinder_settings.py
new file mode 100644
index 0000000..2942dd4
--- /dev/null
+++ b/horizon/files/horizon_settings/_cinder_settings.py
@@ -0,0 +1,17 @@
+{%- from "horizon/map.jinja" import server with context %}
+
+{%- if server.app is defined %}
+ {%- set app = server.app.app_name %}
+{%- else %}
+ {%- set app = server %}
+{%- endif %}
+
+{%- if app.openstack_cinder_features is defined %}
+# The OPENSTACK_CINDER_FEATURES settings can be used to enable optional
+# services provided by cinder that is not exposed by its extension API.
+OPENSTACK_CINDER_FEATURES = {
+ {%- for key, value in app.openstack_cinder_features.iteritems() %}
+ "{{ key }}": {{ value }}{% if not loop.last %},{% endif %}
+ {%- endfor %}
+}
+{%- endif %}
diff --git a/horizon/files/local_settings/ocata_settings.py b/horizon/files/local_settings/ocata_settings.py
index aebbc5e..e5388f0 100644
--- a/horizon/files/local_settings/ocata_settings.py
+++ b/horizon/files/local_settings/ocata_settings.py
@@ -80,5 +80,6 @@
{% include "horizon/files/horizon_settings/_glance_settings.py" %}
{% include "horizon/files/horizon_settings/_neutron_settings.py" %}
{% include "horizon/files/horizon_settings/_heat_settings.py" %}
+{% include "horizon/files/horizon_settings/_cinder_settings.py" %}
{% include "horizon/files/horizon_settings/_websso_settings.py" %}
{% include "horizon/files/horizon_settings/_ssl_settings.py" %}
diff --git a/horizon/files/local_settings/queens_settings.py b/horizon/files/local_settings/queens_settings.py
index d161c42..666e909 100644
--- a/horizon/files/local_settings/queens_settings.py
+++ b/horizon/files/local_settings/queens_settings.py
@@ -79,5 +79,6 @@
{% include "horizon/files/horizon_settings/_glance_settings.py" %}
{% include "horizon/files/horizon_settings/_neutron_settings.py" %}
{% include "horizon/files/horizon_settings/_heat_settings.py" %}
+{% include "horizon/files/horizon_settings/_cinder_settings.py" %}
{% include "horizon/files/horizon_settings/_websso_settings.py" %}
{% include "horizon/files/horizon_settings/_ssl_settings.py" %}