I have a specific issue with VMs not respecting the hostname and IP address specified through the API.
The vCloud Director portal appears to show the correct details but the instances themselves have the details from the vApp Template.
I’ve attached a code snippet. There are two methods: StartInstances which either calls vApp.RecomposeVapp (for adding VMs from a template to an existing vApp) or _vdc.ComposeVapp (to add to a new vApp).
I’ve noted that once the VM is created, the guest customization is not enabled (see image attached). The screenshot shows the VM stopped.
I believe this is the root cause of the machine name and ip address not being set within the instance. Any assistance on how to enable the customization in these two use cases would be appreciated.
I see in your code you are setting the ComputerName and the Info properties. There is also another property which says whether the guest customization is enabled or not. Try setting that to true and then perform the recompose/compose.