From 20c5e4e193c842a3e5a7df1d94170fdfda83006e Mon Sep 17 00:00:00 2001 From: Jason Zhang Date: Mon, 4 Mar 2013 11:45:22 -0800 Subject: [PATCH] Moved the configuration variables. Moved the configuration variables from dhcp agent to linux interface so l3-agent works with Metadriver. Also removed the unnecessary configuration variables from quantum debug agent because of the above modification. Fixes: bug #1138757 Change-Id: Ib23fee18a08ef1c531feb05d98c9a76f5385a4ff --- quantum/agent/dhcp_agent.py | 13 ------------- quantum/agent/linux/interface.py | 15 ++++++++++++++- quantum/debug/debug_agent.py | 13 ------------- 3 files changed, 14 insertions(+), 27 deletions(-) diff --git a/quantum/agent/dhcp_agent.py b/quantum/agent/dhcp_agent.py index 89aa5604dc..f19156a6eb 100644 --- a/quantum/agent/dhcp_agent.py +++ b/quantum/agent/dhcp_agent.py @@ -455,19 +455,6 @@ class NetworkCache(object): class DeviceManager(object): OPTS = [ - cfg.StrOpt('admin_user', - help=_("Admin username")), - cfg.StrOpt('admin_password', - help=_("Admin password"), - secret=True), - cfg.StrOpt('admin_tenant_name', - help=_("Admin tenant name")), - cfg.StrOpt('auth_url', - help=_("Authentication URL")), - cfg.StrOpt('auth_strategy', default='keystone', - help=_("The type of authentication to use")), - cfg.StrOpt('auth_region', - help=_("Authentication region")), cfg.StrOpt('interface_driver', help=_("The driver used to manage the virtual interface.")) ] diff --git a/quantum/agent/linux/interface.py b/quantum/agent/linux/interface.py index 496f090545..b07cbbd57f 100644 --- a/quantum/agent/linux/interface.py +++ b/quantum/agent/linux/interface.py @@ -42,7 +42,20 @@ OPTS = [ cfg.StrOpt('network_device_mtu', help=_('MTU setting for device.')), cfg.StrOpt('meta_flavor_driver_mappings', - help=_('Mapping between flavor and LinuxInterfaceDriver')) + help=_('Mapping between flavor and LinuxInterfaceDriver')), + cfg.StrOpt('admin_user', + help=_("Admin username")), + cfg.StrOpt('admin_password', + help=_("Admin password"), + secret=True), + cfg.StrOpt('admin_tenant_name', + help=_("Admin tenant name")), + cfg.StrOpt('auth_url', + help=_("Authentication URL")), + cfg.StrOpt('auth_strategy', default='keystone', + help=_("The type of authentication to use")), + cfg.StrOpt('auth_region', + help=_("Authentication region")), ] diff --git a/quantum/debug/debug_agent.py b/quantum/debug/debug_agent.py index 156eec416d..e841f3a3e5 100644 --- a/quantum/debug/debug_agent.py +++ b/quantum/debug/debug_agent.py @@ -37,19 +37,6 @@ class QuantumDebugAgent(): OPTS = [ # Needed for drivers - cfg.StrOpt('admin_user', - help=_("Admin user")), - cfg.StrOpt('admin_password', - help=_("Admin password"), - secret=True), - cfg.StrOpt('admin_tenant_name', - help=_("Admin tenant name")), - cfg.StrOpt('auth_url', - help=_("Authentication URL")), - cfg.StrOpt('auth_strategy', default='keystone', - help=_("The type of authentication to use")), - cfg.StrOpt('auth_region', - help=_("Authentication region")), cfg.BoolOpt('use_namespaces', default=True, help=_("Use Linux network namespaces")), cfg.StrOpt('interface_driver',