Browse code

Merge "Add support for setting Neutron DHCP agent options."

Jenkins authored on 2013/08/28 01:07:52
Showing 1 changed files
... ...
@@ -542,6 +542,14 @@ function _configure_neutron_dhcp_agent() {
542 542
     iniset $Q_DHCP_CONF_FILE DEFAULT use_namespaces $Q_USE_NAMESPACE
543 543
     iniset $Q_DHCP_CONF_FILE DEFAULT root_helper "$Q_RR_COMMAND"
544 544
 
545
+    # Define extra "DEFAULT" configuration options when q-dhcp is configured by
546
+    # defining the array ``Q_DHCP_EXTRA_DEFAULT_OPTS``.
547
+    # For Example: ``Q_DHCP_EXTRA_DEFAULT_OPTS=(foo=true bar=2)``
548
+    for I in "${Q_DHCP_EXTRA_DEFAULT_OPTS[@]}"; do
549
+        # Replace the first '=' with ' ' for iniset syntax
550
+        iniset $Q_DHCP_CONF_FILE DEFAULT ${I/=/ }
551
+    done
552
+
545 553
     _neutron_setup_interface_driver $Q_DHCP_CONF_FILE
546 554
 
547 555
     neutron_plugin_configure_dhcp_agent