From aa87d336f7838aa26450dd971e8f3b847e560948 Mon Sep 17 00:00:00 2001 From: "Stephen B. Ma" Date: Fri, 9 Jun 2017 15:19:07 -0700 Subject: [PATCH] Fix ml2_hpe section not found error --- baremetal_network_provisioning/managers.py | 8 ++++++++ baremetal_network_provisioning/ml2/mechanism_hpe.py | 9 +-------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/baremetal_network_provisioning/managers.py b/baremetal_network_provisioning/managers.py index b76e1ef..6c38c38 100644 --- a/baremetal_network_provisioning/managers.py +++ b/baremetal_network_provisioning/managers.py @@ -21,6 +21,14 @@ LOG = log.getLogger(__name__) +driver_opts = [ + cfg.StrOpt('provisioning_driver', + default='baremetal_network_provisioning.drivers' + '.snmp_provisioning_driver.SNMPProvisioningDriver', + help=_("Driver to provision networks on the switches in" + "the cloud fabric")), +] +cfg.CONF.register_opts(driver_opts, "ml2_hpe") class ProvisioningManager(stevedore.named.NamedExtensionManager): """Manage provisioning drivers for BNP.""" diff --git a/baremetal_network_provisioning/ml2/mechanism_hpe.py b/baremetal_network_provisioning/ml2/mechanism_hpe.py index 949ecda..6fc0cc5 100644 --- a/baremetal_network_provisioning/ml2/mechanism_hpe.py +++ b/baremetal_network_provisioning/ml2/mechanism_hpe.py @@ -38,14 +38,7 @@ LOG = logging.getLogger(__name__) -driver_opts = [ - cfg.StrOpt('provisioning_driver', - default='baremetal_network_provisioning.drivers' - '.snmp_provisioning_driver.SNMPProvisioningDriver', - help=_("Driver to provision networks on the switches in" - "the cloud fabric")), -] -cfg.CONF.register_opts(driver_opts, "ml2_hpe") + param_opts = [ cfg.IntOpt('snmp_retries', default=5,