Question on 'networks' parameter for VMWare cloud module

39 views
Skip to first unread message

EspressoBeanies

unread,
Apr 20, 2018, 10:58:29 AM4/20/18
to Ansible Project
I have a question about the 'networks' parameter for the VMWare cloud module. How do the options in this particular parameter get passed to the operating system during the initial deployment or setup process? With the virtual machine NIC settings for any ESXi instance, there is no place to define the IP address, netmask, gateway, etc... and with Linux operating systems, I can only get around this via Kickstart. Could someone clarify how this mechanism works when setting up new VMWare vm's using Ansible?

Sebastien Desbois

unread,
Apr 27, 2018, 12:51:16 PM4/27/18
to Ansible Project
Hello,

Can you precise which module you are using exactly?

EspressoBeanies

unread,
May 15, 2018, 10:26:50 AM5/15/18
to Ansible Project
Hi Sebastien, apologies for the delay. 

I'm using the 'vmware_guest' module. From the documentation I've been reading, it seems the 'network' actions have no effect on the VM itself as those have to be assigned at the OS-level, not the VM-level. I don't understand why the authors added that as it's confusing, but maybe it's strictly for setting up a new ESXi instance.

Nick Rogers

unread,
May 15, 2018, 3:11:39 PM5/15/18
to Ansible Project
Ansible creates a sysprep/linuxprep script:

I have a lab with only static IPs and the networks parameter(s) work fine for me when creating new/cloning.

Sebastien Desbois

unread,
May 30, 2018, 5:28:09 AM5/30/18
to Ansible Project
Hello,

If I'm not mistaken, those parameters only work when deploying a VM from a template.
And this template needs to have VMTools (or openvmtools) installed in it.

The network parameters are part of "guest customization specifications" and those specifications are send to the VM through the VMTools.
Reply all
Reply to author
Forward
0 new messages