1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2024-12-25 23:55:24 +00:00

Fixed when net dev vnet

This commit is contained in:
Anatoliy Guskov 2015-06-22 10:13:50 +03:00
parent b8caf3f49a
commit 6f0c016ec8

View file

@ -176,7 +176,7 @@ class wvmInstance(wvmConnect):
result = [] result = []
for net in ctx.xpathEval('/domain/devices/interface'): for net in ctx.xpathEval('/domain/devices/interface'):
mac_host = net.xpathEval('mac/@address')[0].content mac_host = net.xpathEval('mac/@address')[0].content
nic_host = net.xpathEval('source/@network|source/@bridge|source/@dev')[0].content nic_host = net.xpathEval('source/@network|source/@bridge|source/@dev|target/@dev')[0].content
try: try:
net = self.get_network(nic_host) net = self.get_network(nic_host)
ip = get_mac_ipaddr(net, mac_host) ip = get_mac_ipaddr(net, mac_host)