bitkeeper revision 1.1159.170.93 (41e661e138UbGRYHtgaE3FTrqTgzzw)

Add VIF-routing capability to xend. The default is still to bridge.
This commit is contained in:
kaf24@scramble.cl.cam.ac.uk committed 2005-01-13 11:56:17 +00:00
1 parent a2fd27001f
commit e214e5c6c1
6 files changed
+113 -5

No files matched your search

+7 -1
View File
@@ -283,14 +283,18 @@ def configure_vifs(config_devs, vals):
if idx < len(vifs):
d = vifs[idx]
mac = d.get('mac')
if not mac:
mac = randomMAC()
bridge = d.get('bridge')
script = d.get('script')
backend = d.get('backend')
ip = d.get('ip')
else:
mac = randomMAC()
bridge = None
script = None
backend = None
ip = None
config_vif = ['vif']
config_vif.append(['mac', mac])
if bridge:
@@ -299,6 +303,8 @@ def configure_vifs(config_devs, vals):
config_vif.append(['script', script])
if backend:
config_vif.append(['backend', backend])
if ip:
config_vif.append(['ip', ip])
config_devs.append(['device', config_vif])
def configure_vfr(config, vals):
@@ -377,7 +383,7 @@ def preprocess_vifs(opts, vals):
(k, v) = b.strip().split('=', 1)
k = k.strip()
v = v.strip()
if k not in ['mac', 'bridge', 'script', 'backend']:
if k not in ['mac', 'bridge', 'script', 'backend', 'ip']:
opts.err('Invalid vif specifier: ' + vif)
d[k] = v
vifs.append(d)
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.