Closed remi-espie closed 5 months ago
sorry about both last commits, some git mistakes by my side. They were removed by a push force, don't take them into account.
Hi All, I need this too. I'm working on an update that implements what the commenters suggested as the better way.
It is much larger change. I'll submit it as a separate PR against main.
Thanks, Greg
This allows Packer to create and allocate multiple nics to a VM through
switches_names
array.switch_name
is still available to ensure backward compatibility. It also addsmac_addresses
array, which will give the first element as a mac address to the first switch ofswitches_names
, the 2nd element to the 2nd switch, etc.This is quite bare bone, only creating, adding and deleting (if needed) multiple nics the the VM. This answer some of #86 needs but not all of them so I'm not marking it as closed.
Personally tested and working in the following cases:
switch_name
is set (noswitches_names
are set)switches_names
are set (noswitch_name
is set)switches_names
are set