Added config option 'dhcp-agents-per-network' with a default value of 2.

It is only activitated when the 'enable-l3ha' option is True.
This commit is contained in:
Alex Kavanagh 2016-01-20 13:59:54 +00:00
parent 3f70b34be9
commit da4744543b
7 changed files with 20 additions and 2 deletions

View File

@ -185,7 +185,7 @@ options:
type: int
description: |
Number of routers allowed per tenant. A negative value means unlimited.
quota-floatingip:
quota-floatingip:
default: 50
type: int
description: |
@ -398,6 +398,13 @@ options:
description: |
Minimum number of l3 agents to host a router. Only used when enable-l3ha
is True
dhcp-agents-per-network:
default: 2
type: int
description: |
The number of dhcp agents to be deployed per network. This option is
only used if the 'enable-l3ha' option is True. Note that if the Calico
plugin is being used, this option has no effect.
nagios_servicegroups:
default: ""
type: string

View File

@ -174,6 +174,7 @@ class NeutronCCContext(context.NeutronContext):
config('max-l3-agents-per-router')
ctxt['min_l3_agents_per_router'] = \
config('min-l3-agents-per-router')
ctxt['dhcp_agents_per_network'] = config('dhcp-agents-per-network')
ctxt['overlay_network_type'] = self.neutron_overlay_network_type
ctxt['external_network'] = config('neutron-external-network')
if config('neutron-plugin') in ['vsp']:

View File

@ -47,6 +47,8 @@ neutron_firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptable
{% if neutron_plugin == 'Calico' -%}
dhcp_agents_per_network = 1000
{% else -%}
dhcp_agents_per_network = {{ dhcp_agents_per_network }}
{% endif -%}
{% include "parts/rabbitmq" %}
@ -82,7 +84,7 @@ quota_security_group_rule = {{ quota_security_group_rule }}
quota_items = network,subnet,port
{% endif -%}
quota_network = {{ quota_network }}
quota_subnet = {{ quota_subnet }}
quota_subnet = {{ quota_subnet }}
quota_port = {{ quota_port }}
quota_vip = {{ quota_vip }}
quota_pool = {{ quota_pool }}

View File

@ -47,6 +47,8 @@ neutron_firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptable
{% if neutron_plugin == 'Calico' -%}
dhcp_agents_per_network = 1000
{% else -%}
dhcp_agents_per_network = {{ dhcp_agents_per_network }}
{% endif -%}
{% include "parts/rabbitmq" %}

View File

@ -51,6 +51,8 @@ neutron_firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptable
{% if neutron_plugin == 'Calico' -%}
dhcp_agents_per_network = 1000
{% else -%}
dhcp_agents_per_network = {{ dhcp_agents_per_network }}
{% endif -%}
notify_nova_on_port_status_changes = True

View File

@ -51,6 +51,8 @@ neutron_firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptable
{% if neutron_plugin == 'Calico' -%}
dhcp_agents_per_network = 1000
{% else -%}
dhcp_agents_per_network = {{ dhcp_agents_per_network }}
{% endif -%}
notify_nova_on_port_status_changes = True

View File

@ -284,6 +284,7 @@ class NeutronCCContextTest(CharmTestCase):
self.test_config.set('plumgrid-password', 'plumgrid')
self.test_config.set('plumgrid-virtual-ip', '192.168.100.250')
self.test_config.set('enable-ml2-port-security', True)
self.test_config.set('dhcp-agents-per-network', 3)
def tearDown(self):
super(NeutronCCContextTest, self).tearDown()
@ -376,6 +377,7 @@ class NeutronCCContextTest(CharmTestCase):
'overlay_network_type': 'gre',
'max_l3_agents_per_router': 2,
'min_l3_agents_per_router': 2,
'dhcp_agents_per_network': 3,
'quota_floatingip': 50,
'quota_health_monitors': -1,
'quota_member': -1,