make sure nic is always defined (#2678)

This commit is contained in:
Brian Coca 2016-08-05 19:02:26 -04:00 committed by GitHub
parent 33716b1837
commit 7a73e2a3aa

View file

@ -333,6 +333,7 @@ def vm_start(conn, vmname, hostname=None, ip=None, netmask=None, gateway=None,
vm = conn.vms.get(name=vmname)
use_cloud_init = False
nics = None
nic = None
if hostname or ip or netmask or gateway or domain or dns or rootpw or key:
use_cloud_init = True
if ip and netmask and gateway: