Disable "DirectPath I/O" when creating host in Vmware compute resource

Hi all. I am trying to create a host using a vmware compute resource. When I create the host with interfaces_attributes → compute_attributes → type: “VirtualVmxnet3”, the VM is created with “DirectPath I/O” enabled on the NIC. That is a problem for me. I cannot figure out with which compute_attribute I can disable this “DirectPath I/O”. Do you know?

I am using ansible:

- name: "Create a VM - Kickstart {{ server_name }} on vcenter {{ compute_resource }}"
  theforeman.foreman.host:
    name: "{{ server_name }}"
    ip: "{{ ip }}"
    compute_resource: "{{ compute_resource }}"
    location: "{{ location }}"
    subnet: "{{ subnet }}"
    state: present
    build: true
    interfaces_attributes:
      - type: "interface"
        compute_attributes:
          type: "VirtualVmxnet3"
          network: "{{ vmware_network }}"
    compute_attributes:
      volumes_attributes:
        0:
          thin: true
          name: "Hard disk"
          mode: "persistent"
          size_gb: "{{ disk_gb }}"
          datastore: "{{ vmware_datastore }}"
      scsi_controllers:
        - type: "ParaVirtualSCSIController"
          key: 1000
      cluster: "{{ vmware_cluster }}"
      path: "/Datacenters/{{ vmware_datacenter }}/{{ vmware_folder }}"
      guest_id: "rhel8_64Guest"
      corespersocket: 1
      start: "1"
      cpus: "{{ cpus }}"
      memory_mb: "{{ memory_mb }}"
      cpuHotAddEnabled: 1
      memoryHotAddEnabled: 1
      firmware: "bios"
      add_cdrom: 1

    provision_method: "bootdisk"
    ptable: "Kickstart default GITO"
    pxe_loader: "PXELinux BIOS"
    operatingsystem: "{{ operatingsystem }}"
    kickstart_repository: "Red Hat Enterprise Linux 8 for x86_64 - BaseOS Kickstart {{ operatingsystem.split(' ')[1] }}"
    root_pass: "{{ root_pass }}"

I can’t find one either.

Can you perform the same action via the UI somehow?

Yes via the UI, it is quite easy to disable.
In the vmx file, it is defined with:

ethernet0.uptCompatibility = "TRUE"

Where do I set this in the Foreman UI?

I don’t think you can. Either fog-vsphere or Foreman is rather limited when it comes to setting “advanced” options for VMs. There have been a lot of cases on the forums in recent years where people searched for ways to set some rather special options for VMs, and the answer was usually “you can’t do that via Foreman”.
Our own VMWare team is “workarounding” this by applying certain changes to VMs automatically during our monthly update windows, where VMs are scheduled to reboot anyway, but this is a rather hackish workaround and probably not suitable to everyone.

I would assume this is through VSphere directly, not through Foreman, correct?

Oh yeah sorry, I meant the vSphere UI…

Yeah, if it’s not exposed right now in Foreman, Ansible/API won’t be able to set this correctly.

@cintrix84 do you know if it would be hard to expose this via fog-vpshere?