Skip to content
This repository was archived by the owner on Jan 8, 2021. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions run.py
Original file line number Diff line number Diff line change
Expand Up @@ -730,7 +730,7 @@ def get_objects(self, vc_obj_type):
if platform:
for index, nic in enumerate(obj.guest.net):
# Interfaces
nic_name = "vNIC{}".format(index)
nic_name = nic.network if nic.network else "vNIC{}".format(index)
log.debug(
"Collecting info for virtual interface '%s'.",
nic_name
Expand All @@ -739,7 +739,7 @@ def get_objects(self, vc_obj_type):
nbt.vm_interface(
virtual_machine=obj_name,
itype=0,
name=nic_name,
name=truncate(nic_name, 64),
mac_address=nic.macAddress,
enabled=nic.connected,
tags=self.tags
Expand Down Expand Up @@ -1098,7 +1098,7 @@ def obj_exists(self, nb_obj_type, vc_data):
elif nb_obj_type == "virtual_interfaces":
query = "?virtual_machine={}&{}={}".format(
quote_plus(vc_data["virtual_machine"]["name"]), query_key,
vc_data[query_key]
quote_plus(vc_data[query_key])
)
else:
query = "?{}={}".format(
Expand Down