Add missing dashboard policies

New dashboard plugins are included in horizon,
new custom policies support need to be added for
those services.

Change conditional check to apply changes when
horizon plugin is enabled, not the service itself.

Closes-Bug: #1664505
Change-Id: I67fcb88fd432b4c7554ddf24e76b28c3aab7c01f
This commit is contained in:
Eduardo Gonzalez 2017-02-14 10:07:16 +00:00
parent 44eee94d09
commit b35901c1ff
2 changed files with 33 additions and 29 deletions

View File

@ -61,17 +61,26 @@
with_items:
- { name: "ceilometer", enabled: "{{ enable_ceilometer }}" }
- { name: "cinder", enabled: "{{ enable_cinder }}" }
- { name: "cloudkitty", enabled: "{{ enable_cloudkitty }}" }
- { name: "cloudkitty", enabled: "{{ enable_horizon_cloudkitty }}" }
- { name: "freezer", enabled: "{{ enable_horizon_freezer }}" }
- { name: "glance", enabled: "{{ enable_glance }}" }
- { name: "heat", enabled: "{{ enable_heat }}" }
- { name: "ironic", enabled: "{{ enable_ironic }}" }
- { name: "ironic", enabled: "{{ enable_horizon_ironic }}" }
- { name: "keystone", enabled: "{{ enable_keystone }}" }
- { name: "manila", enabled: "{{ enable_manila }}" }
- { name: "karbor", enabled: "{{ enable_horizon_karbor }}" }
- { name: "magnum", enabled: "{{ enable_horizon_magnum }}" }
- { name: "manila", enabled: "{{ enable_horizon_manila }}" }
- { name: "mistral", enabled: "{{ enable_horizon_mistral }}" }
- { name: "murano", enabled: "{{ enable_horizon_murano }}" }
- { name: "neutron", enabled: "{{ enable_neutron }}" }
- { name: "nova", enabled: "{{ enable_nova }}" }
- { name: "sahara", enabled: "{{ enable_sahara }}" }
- { name: "senlin", enabled: "{{ enable_senlin }}" }
- { name: "trove", enabled: "{{ enable_trove }}" }
- { name: "sahara", enabled: "{{ enable_horizon_sahara }}" }
- { name: "searchlight", enabled: "{{ enable_horizon_searchlight }}" }
- { name: "senlin", enabled: "{{ enable_horizon_senlin }}" }
- { name: "solum", enabled: "{{ enable_horizon_solum }}" }
- { name: "tacker", enabled: "{{ enable_horizon_tacker }}" }
- { name: "trove", enabled: "{{ enable_horizon_trove }}" }
- { name: "watcher", enabled: "{{ enable_horizon_watcher }}" }
- name: Copying over existing policy.json
vars:
@ -83,23 +92,9 @@
when:
- horizon.enabled | bool
- inventory_hostname in groups[horizon.group]
- item[0]['enabled'] | bool
- item[1]['stat']['exists']
with_together:
- [{ name: "ceilometer", enabled: "{{ enable_ceilometer }}" },
{ name: "cinder", enabled: "{{ enable_cinder }}" },
{ name: "cloudkitty", enabled: "{{ enable_cloudkitty }}" },
{ name: "glance", enabled: "{{ enable_glance }}" },
{ name: "heat", enabled: "{{ enable_heat }}" },
{ name: "ironic", enabled: "{{ enable_ironic }}" },
{ name: "keystone", enabled: "{{ enable_keystone }}" },
{ name: "manila", enabled: "{{ enable_manila }}" },
{ name: "neutron", enabled: "{{ enable_neutron }}" },
{ name: "nova", enabled: "{{ enable_nova }}" },
{ name: "sahara", enabled: "{{ enable_sahara }}" },
{ name: "senlin", enabled: "{{ enable_senlin }}" },
{ name: "trove", enabled: "{{ enable_trove }}" }]
- "{{ custom_policy.results }}"
- item.item.enabled | bool
- item.stat.exists
with_items: "{{ custom_policy.results }}"
- name: Check horizon container
vars:

View File

@ -4,17 +4,26 @@
{% set services = [
( 'ceilometer', enable_ceilometer ),
( 'cinder', enable_cinder ),
( 'cloudkitty', enable_cloudkitty ),
( 'cloudkitty', enable_horizon_cloudkitty ),
( 'freezer', enable_horizon_freezer ),
( 'glance', enable_glance ),
( 'heat', enable_heat ),
( 'ironic', enable_ironic ),
( 'ironic', enable_horizon_ironic ),
( 'keystone', enable_keystone ),
( 'manila', enable_manila ),
( 'karbor', enable_horizon_karbor ),
( 'magnum', enable_horizon_magnum ),
( 'manila', enable_horizon_manila ),
( 'mistral', enable_horizon_mistral ),
( 'murano', enable_horizon_murano ),
( 'neutron', enable_neutron ),
( 'nova', enable_nova ),
( 'sahara', enable_sahara ),
( 'senlin', enable_senlin ),
( 'trove', enable_trove )
( 'sahara', enable_horizon_sahara ),
( 'searchlight', enable_horizon_searchlight ),
( 'senlin', enable_horizon_senlin ),
( 'solum', enable_horizon_solum ),
( 'tacker', enable_horizon_tacker ),
( 'trove', enable_horizon_trove ),
( 'watcher', enable_horizon_watcher )
] %}
{