# Can you add guestinfo. to a VM in vsphere through ansible?

**URL:** <https://forum.ansible.com/t/can-you-add-guestinfo-to-a-vm-in-vsphere-through-ansible/23055>\
**Category:** Ansible Project\
**Created:** [November 18, 2016, 5:07pm UTC](https://forum.ansible.com/t/can-you-add-guestinfo-to-a-vm-in-vsphere-through-ansible/23055 "2016-11-18T17:07:07Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Brandon\_Hudlemeyer](https://avatars.discourse-cdn.com/v4/letter/b/c5a1d2/32.png) [@Brandon\_Hudlemeyer](https://forum.ansible.com/u/Brandon_Hudlemeyer)\
**Post date:** [November 18, 2016, 5:07pm UTC](https://forum.ansible.com/t/can-you-add-guestinfo-to-a-vm-in-vsphere-through-ansible/23055/1 "2016-11-18T17:07:07Z")

</div>

I searched and couldn’t find anything saying one way or the other but I am trying to basically build a bunch of Coreos VMs(just for lab and practice) using ansible. I can deploy them just fine but I would like to do what I do in powershell and modify the guestinfo to provide Coreos with its settings on the vms them selves.

The playbook creates the vms just fine their setting just aren’t updated.

My vm\_extra’s info:

vm\_extra\_config:  
guestinfo.coreos.config.data.encoding: “base64”  
guestinfo.interface.0.dhcp: “no”  
guestinfo.coreos.config.data: “{{ base64 }}”  
guestinfo.dns.server.0: “{{ dns }}”  
guestinfo.interface.0.ip.0.address: “{{ item.value.ip }}”  
guestinfo.interface.0.route.0.gateway: “{{ gateway }}”  
guestinfo.interface.0.role: “private”  
guestinfo.interface.0.route.0.destination: “0.0.0.0/0”  
guestinfo.interface.0.name: “ens192”  
guestinfo.hostname: “{{ item.key }}”  
vcpu.hotadd: yes  
mem.hotadd: yes  
notes: Mesos  
folder: Mesos

The note and the folder work fine but nothing else.
