~bgh/nova/qmanager-dhcp

« back to all changes in this revision

Viewing changes to bin/nova-dhcpbridge

  • Committer: Brad Hall
  • Date: 2011-10-02 00:34:49 UTC
  • Revision ID: brad@nicira.com-20111002003449-c93594f62o8zpt2l
Add DHCP support to the QuantumManager

This introduces a new flag "quantum_use_dhcp=<boolean>" which indicates
whether or not to enable dhcp for all of the networks.  If it is set then we
start dnsmasq (and provide it with the IP/MACs from Melange) similar to how
this was done in linux_net before.

Show diffs side-by-side

added added

removed removed

Lines of Context:
90
90
    """Get the list of hosts for a network."""
91
91
    ctxt = context.get_admin_context()
92
92
    network_ref = db.network_get(ctxt, network_id)
93
 
    return linux_net.get_dhcp_leases(ctxt, network_ref)
 
93
    network_manager = utils.import_object(FLAGS.network_manager)
 
94
    return network_manager.get_dhcp_leases_text(ctxt, network_ref)
94
95
 
95
96
 
96
97
def main():