Skip to content

Unable to clone template using customvalues #1462

Open
@ddreggors

Description

@ddreggors
SUMMARY

Deploying the rhcos (CoreOS) ova template we require setting the ignition file for the OS to key off of. We use the cusomvalues key to accomplish this. However, when the play completes we do not see these values in the cloned vm as expected. It does not give error and does not update vm values.

We can easily use GOVC to apply these settings but isn't this ideal as we are already using the vmware_guest task to accomplish this.

ISSUE TYPE
  • Bug Report
COMPONENT NAME

vmware_guest

ANSIBLE VERSION
ansible [core 2.13.4]
  config file = None
  configured module search path = ['/home/ddreggors/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /home/ddreggors/.local/lib/python3.10/site-packages/ansible
  ansible collection location = /home/ddreggors/.ansible/collections:/usr/share/ansible/collections
  executable location = /home/ddreggors/.local/bin/ansible
  python version = 3.10.6 (main, Aug  2 2022, 00:00:00) [GCC 12.1.1 20220507 (Red Hat 12.1.1-1)]
  jinja version = 3.0.3
  libyaml = True
COLLECTION VERSION
Collection       Version
---------------- -------
community.vmware 2.8.0 
CONFIGURATION
No output 
OS / ENVIRONMENT

Fedora 36 Workstation

STEPS TO REPRODUCE
1. Download rhcos ova (https://mirror.openshift.com/pub/openshift-v4/x86_64/dependencies/rhcos/4.10/4.10.16/rhcos-4.10.16-x86_64-vmware.x86_64.ova)
2. Upload ova to folder in vcenter (or in playbook)
3. Clone ova using vmware_guest and set customvalues to add keys and values
4. Run playbook
EXPECTED RESULTS

VM is created with new custom keys and values under Edit Settings->VM Options-Advanced->Edit Configuration

ACTUAL RESULTS

VM is created with no custom keys or values

TASK [Create bootstrap VM from the template] ********************************************************************************************************************************
changed: [localhost] => (item={'name': 'bootstrap', 'macaddr': '00:50:56:a8:aa:a1', 'ipaddr': '192.168.86.181', 'cpu': 4, 'ram': 16384})

PLAY RECAP ******************************************************************************************************************************************************************
localhost                  : ok=3    changed=2    unreachable=0    failed=0    skipped=1    rescued=0    ignored=0   

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugThis issue/PR relates to a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions