]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
Add nova_api_insecure flag to neutron
authorPaul Ward <wpward@us.ibm.com>
Sat, 12 Apr 2014 15:18:18 +0000 (10:18 -0500)
committerPaul Ward <wpward@us.ibm.com>
Sun, 13 Apr 2014 15:10:35 +0000 (10:10 -0500)
Neutron did not have any way to allow SSL validation problems in the
novaclient similar to the way nova has the neutron_api_insecure flag.
This change adds the nova_api_insecure flag to the neutron config and
also passes it in the novaclient instantiation.

Change-Id: Ifed581df253c01fab9dc1f22c8187876271b378e
Closes-Bug: #1306822

etc/neutron.conf
neutron/common/config.py
neutron/notifiers/nova.py

index 193b0260a69318bd9e44b64f77733037e88e0d26..f116cdfd35725c3a0aff33ec5b8ee3278ca875be 100644 (file)
@@ -320,6 +320,9 @@ notification_driver = neutron.openstack.common.notifier.rpc_notifier
 # Authorization URL for connection to nova in admin context.
 # nova_admin_auth_url =
 
+# Boolean to control ignoring SSL errors on the nova url
+# nova_api_insecure = False
+
 # Number of seconds between sending events to nova if there are any events to send
 # send_events_interval = 2
 
index 25558311c30d4cbf9515f8f74d79318f570a8041..2ac76dad1267d787777fa12da5a1ba32469c75fd 100644 (file)
@@ -100,6 +100,8 @@ core_opts = [
                default='http://localhost:5000/v2.0',
                help=_('Authorization URL for connecting to nova in admin '
                       'context')),
+    cfg.BoolOpt('nova_api_insecure', default=False,
+                help=_("If True, ignore any SSL validation issues")),
     cfg.StrOpt('nova_region_name',
                help=_('Name of nova region to use. Useful if keystone manages'
                       ' more than one region.')),
index e8c560e48e127aa534f2e695b7c0884b0fe31f87..4d268ec3299639f304637a354b293330a43610e9 100644 (file)
@@ -48,6 +48,7 @@ class Notifier(object):
             project_id=None,
             tenant_id=cfg.CONF.nova_admin_tenant_id,
             auth_url=cfg.CONF.nova_admin_auth_url,
+            insecure=cfg.CONF.nova_api_insecure,
             bypass_url=bypass_url,
             region_name=cfg.CONF.nova_region_name,
             extensions=[server_external_events])