From c910b470e61a35230bc7ddaced13c3d51fac32fd Mon Sep 17 00:00:00 2001 From: andy Date: Thu, 24 Jun 2010 04:11:53 +0100 Subject: re-added cloudpipe Conflicts: bin/nova-manage nova/auth/users.py nova/compute/network.py --- nova/compute/network.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'nova/compute') diff --git a/nova/compute/network.py b/nova/compute/network.py index 618e7bffb..3001b1375 100644 --- a/nova/compute/network.py +++ b/nova/compute/network.py @@ -51,6 +51,11 @@ flags.DEFINE_string('private_range', '10.0.0.0/8', 'Private IP address block') logging.getLogger().setLevel(logging.DEBUG) +# CLEANUP: +# TODO(ja): Save the IPs at the top of each subnet for cloudpipe vpn clients +# TODO(ja): use singleton for usermanager instead of self.manager in vlanpool et al +# TODO(ja): does vlanpool "keeper" need to know the min/max - shouldn't FLAGS always win? +# TODO(joshua): Save the IPs at the top of each subnet for cloudpipe vpn clients class BaseNetwork(datastore.RedisModel): bridge_gets_ip = False @@ -97,6 +102,11 @@ class BaseNetwork(datastore.RedisModel): def bridge_name(self): return "br%s" % (self["vlan"]) + def range(self): + # the .2 address is always CloudPipe + for idx in range(3, len(self.network)-2): + yield self.network[idx] + @property def user(self): return users.UserManager.instance().get_user(self['user_id']) -- cgit