~openstack-charmers-archive/charms/trusty/neutron-openvswitch/next

« back to all changes in this revision

Viewing changes to hooks/neutron_ovs_context.py

  • Committer: james.page at ubuntu
  • Date: 2015-09-15 07:47:30 UTC
  • mfrom: (85.2.8 local-metadata)
  • Revision ID: james.page@ubuntu.com-20150915074730-jey2hm36p4tt6did
[gnuoy,r=james-page] Add support for local DHCP and Metadata agents

This change allows nova-compute nodes to also run Neutron DHCP and Metadata
agents, allowing deploying without the neutron-gateway charm in VLAN and
flat networking configurations.

Only useful if l3 routing, vpnaas, fwaas and lbaas services are not required.

Show diffs side-by-side

added added

removed removed

Lines of Context:
108
108
    return secret
109
109
 
110
110
 
111
 
class DVRSharedSecretContext(OSContextGenerator):
 
111
class SharedSecretContext(OSContextGenerator):
112
112
 
113
113
    def __call__(self):
114
 
        if NeutronAPIContext()()['enable_dvr']:
 
114
        if NeutronAPIContext()()['enable_dvr'] or \
 
115
                config('enable-local-dhcp-and-metadata'):
115
116
            ctxt = {
116
117
                'shared_secret': get_shared_secret(),
117
118
                'local_ip': resolve_address(),