Commit 1bc7ae27 by Kálmán Viktor

vm: access dict with keys

parent 9b3849c1
...@@ -400,9 +400,8 @@ class Instance(AclBase, VirtualMachineDescModel, TimeStampedModel): ...@@ -400,9 +400,8 @@ class Instance(AclBase, VirtualMachineDescModel, TimeStampedModel):
inst.disks.add(*[disk.get_exclusive() for disk in disks]) inst.disks.add(*[disk.get_exclusive() for disk in disks])
for net in networks: for net in networks:
i = Interface.create(instance=inst, vlan=net.vlan, owner=owner, i = Interface.create(instance=inst, vlan=net['vlan'], owner=owner,
managed=net.managed) managed=net['managed'])
if i.host: if i.host:
i.host.enable_net() i.host.enable_net()
port, proto = ACCESS_PROTOCOLS[i.instance.access_method][1:3] port, proto = ACCESS_PROTOCOLS[i.instance.access_method][1:3]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment