From e4a523f543e59d92ab227b5bcfaad09fc171b6a9 Mon Sep 17 00:00:00 2001 From: Joe Mills Date: Mon, 28 Oct 2013 07:38:55 +0000 Subject: [PATCH] Cleanup unused settings, use interface_driver setter * Remove unused MIDONET specific settings from nova.conf * Remove unused MIDONET specific settings from dhcp_agent.ini * Move the interface_driver settings to the proper setting function so that it can be used by lbaas_agent.ini as well. Change-Id: Id686ff5f55db00bce42b8a2bd56e7655c73211fb Closes-Bug: #1245401 --- lib/neutron_plugins/midonet | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/lib/neutron_plugins/midonet b/lib/neutron_plugins/midonet index cf45a9d11d..e406146bbe 100644 --- a/lib/neutron_plugins/midonet +++ b/lib/neutron_plugins/midonet @@ -32,23 +32,10 @@ function neutron_plugin_configure_debug_command() { function neutron_plugin_configure_dhcp_agent() { DHCP_DRIVER=${DHCP_DRIVER:-"neutron.plugins.midonet.agent.midonet_driver.DhcpNoOpDriver"} - DHCP_INTERFACE_DRIVER=${DHCP_INTEFACE_DRIVER:-"neutron.plugins.midonet.agent.midonet_driver.MidonetInterfaceDriver"} + neutron_plugin_setup_interface_driver $Q_DHCP_CONF_FILE iniset $Q_DHCP_CONF_FILE DEFAULT dhcp_driver $DHCP_DRIVER - iniset $Q_DHCP_CONF_FILE DEFAULT interface_driver $DHCP_INTERFACE_DRIVER iniset $Q_DHCP_CONF_FILE DEFAULT use_namespaces True iniset $Q_DHCP_CONF_FILE DEFAULT enable_isolated_metadata True - if [[ "$MIDONET_API_URI" != "" ]]; then - iniset $Q_DHCP_CONF_FILE MIDONET midonet_uri "$MIDONET_API_URI" - fi - if [[ "$MIDONET_USERNAME" != "" ]]; then - iniset $Q_DHCP_CONF_FILE MIDONET username "$MIDONET_USERNAME" - fi - if [[ "$MIDONET_PASSWORD" != "" ]]; then - iniset $Q_DHCP_CONF_FILE MIDONET password "$MIDONET_PASSWORD" - fi - if [[ "$MIDONET_PROJECT_ID" != "" ]]; then - iniset $Q_DHCP_CONF_FILE MIDONET project_id "$MIDONET_PROJECT_ID" - fi } function neutron_plugin_configure_l3_agent() { @@ -78,8 +65,8 @@ function neutron_plugin_configure_service() { } function neutron_plugin_setup_interface_driver() { - # May change in the future - : + local conf_file=$1 + iniset $conf_file DEFAULT interface_driver neutron.agent.linux.interface.MidonetInterfaceDriver } function has_neutron_plugin_security_group() {