]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
Move dhcp_lease_duration into DHCP agent config options list
authorIhar Hrachyshka <ihrachys@redhat.com>
Fri, 13 Nov 2015 11:17:43 +0000 (12:17 +0100)
committerIhar Hrachyshka <ihrachys@redhat.com>
Fri, 13 Nov 2015 11:21:44 +0000 (12:21 +0100)
It is DHCP agent specific, and so it should not be present in
neutron.conf or be reported as a valid option for other services.

Also modified the help message slightly to avoid mentioning dnsmasq
since the option could in theory be used by alternative dhcp drivers.

Change-Id: I66bcea1c3a6ce6fa9ce56ea8137a94858f18dc5a

etc/dhcp_agent.ini
etc/neutron.conf
neutron/agent/dhcp/config.py
neutron/common/config.py

index a7e5547ba31e082675597e9f92ad6e2c5082e059..21e12488fa83fc3f83739c586ed3250b1caaaa6d 100644 (file)
@@ -95,6 +95,9 @@
 # If the timeout expires, ovs commands will fail with ALARMCLOCK error.
 # ovs_vsctl_timeout = 10
 
+# DHCP lease duration (in seconds). Use -1 for infinite lease times.
+# dhcp_lease_duration = 86400
+
 [AGENT]
 # Log agent heartbeats from this DHCP agent
 # log_agent_heartbeats = False
index 3140c2c352e9b1da9ecf07254704838cbd6f76c7..763786b8192c6300e653c183f2640d54b322832f 100644 (file)
 # Maximum amount of retries to generate a unique MAC address
 # mac_generation_retries = 16
 
-# DHCP Lease duration (in seconds).  Use -1 to
-# tell dnsmasq to use infinite lease times.
-# dhcp_lease_duration = 86400
-
 # Domain to use for building the hostnames
 # dns_domain = openstacklocal
 
index a6c00b9e17fb2a7eaf3e85ca2590070ee4ee59fa..837b7467ae57f22e0748cea8a1848315940f890f 100644 (file)
@@ -45,6 +45,10 @@ DHCP_OPTS = [
                       'neutron.conf as dns_domain. It will removed from here '
                       'in a future release'),
                deprecated_for_removal=True),
+    cfg.IntOpt('dhcp_lease_duration', default=86400,
+               deprecated_name='dhcp_lease_time',
+               help=_('DHCP lease duration (in seconds). Use -1 for infinite '
+                      'lease times.')),
 ]
 
 DNSMASQ_OPTS = [
index 1f07ba00a0da966acff926db62d9288831db81f4..38ae94f384e211b7ac6d6d2af366922a700b1d5c 100644 (file)
@@ -81,10 +81,6 @@ core_opts = [
     cfg.BoolOpt('ipv6_pd_enabled', default=False,
                 help=_("Enables IPv6 Prefix Delegation for automatic subnet "
                        "CIDR allocation")),
-    cfg.IntOpt('dhcp_lease_duration', default=86400,
-               deprecated_name='dhcp_lease_time',
-               help=_("DHCP lease duration (in seconds). Use -1 to tell "
-                      "dnsmasq to use infinite lease times.")),
     cfg.StrOpt('dns_domain',
                default='openstacklocal',
                help=_('Domain to use for building the hostnames')),