From 4ca1444fadaf55fcd01ccf14c41cbadaacd59e20 Mon Sep 17 00:00:00 2001 From: Bertrand Lallau Date: Tue, 7 Mar 2017 18:11:13 +0100 Subject: [PATCH] Update Searchlight resource_plugin configuration Activate resource_plugin only if related Openstack services are enabled. Change-Id: Iff37c8738513661d2defe7fb7614b526864b1cc2 --- .../searchlight/templates/searchlight.conf.j2 | 49 ++++++++++++------- 1 file changed, 31 insertions(+), 18 deletions(-) diff --git a/ansible/roles/searchlight/templates/searchlight.conf.j2 b/ansible/roles/searchlight/templates/searchlight.conf.j2 index 3317fca1fe..6d95da5d2d 100644 --- a/ansible/roles/searchlight/templates/searchlight.conf.j2 +++ b/ansible/roles/searchlight/templates/searchlight.conf.j2 @@ -51,40 +51,53 @@ memcache_security_strategy = ENCRYPT memcache_secret_key = {{ memcache_secret_key }} memcached_servers = {% for host in groups['memcached'] %}{% if orchestration_engine == 'KUBERNETES' %}memcached{% else %}{{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}{% endif %}:{{ memcached_port }}{% if not loop.last %},{% endif %}{% endfor %} +[resource_plugin:os_cinder_volume] +enabled = {{ enable_cinder | bool }} + +[resource_plugin:os_cinder_snapshot] +enabled = {{ enable_cinder | bool }} + [resource_plugin:os_designate_zone] -enabled = False +enabled = {{ enable_designate | bool }} [resource_plugin:os_designate_recordset] -enabled = False +enabled = {{ enable_designate | bool }} -{% if not enable_swift | bool %} [resource_plugin:os_swift_account] -enabled = False +enabled = {{ enable_swift | bool }} [resource_plugin:os_swift_container] -enabled = False +enabled = {{ enable_swift | bool }} [resource_plugin:os_swift_object] -enabled = False -{% endif %} +enabled = {{ enable_swift | bool }} -{% if not enable_nova | bool %} [resource_plugin:os_server_nova] -enabled = False -{% endif %} +enabled = {{ enable_nova | bool }} + +[resource_plugin:os_nova_hypervisor] +enabled = {{ enable_nova | bool }} + +[resource_plugin:os_nova_flavor] +enabled = {{ enable_nova | bool }} + +[resource_plugin:os_nova_servergroup] +enabled = {{ enable_nova | bool }} -{% if not enable_glance | bool %} [resource_plugin:os_glance_image] -enabled = False +enabled = {{ enable_glance | bool }} [resource_plugin:os_glance_metadef] -enabled = False -{% endif %} +enabled = {{ enable_glance | bool }} -{% if not enable_neutron | bool %} [resource_plugin:os_neutron_net] -enabled = False +enabled = {{ enable_neutron | bool }} [resource_plugin:os_neutron_port] -enabled = False -{% endif %} +enabled = {{ enable_neutron | bool }} + +[resource_plugin:os_neutron_floatingip] +enabled = {{ enable_neutron | bool }} + +[resource_plugin:os_neutron_security_group] +enabled = {{ enable_neutron | bool }}