VMware Cloud Community
CloudInfraTeam
Enthusiast
Enthusiast

Getting vcac:virtualmachine objet during machine provisioning

Hello,    

We currently started using vRO 7.0.1 connected to vRA 7.0.1.

We use the Event Broker to catch a machine provisioning event during deploying a virtual machine from a blueprint.

We catch the machine provisioning state during the event "Building Machine (PRE)" to create DNS Records and AD Computer Accounts, and another catch that needs to occur after the VM is cloned from the template (after Building Machine (POST)).

during the later event, we need to get ahold of the vCac:Virtualmachine object to make a guest os restart during the workflow after we make some configuration changes. however, it seems like i can't get the object until all the provisioning workflow (that happens in the vRA) are completed.

I am trying to get the vcac vm from the action GetCatalogResourceByUserName (using the user that created the machine), and after that GetVCACVMfromCatalogResource, and then matching by the machine ID (i'm getting from the schema).

I've tried making a subscription both in Building Machine (POST), MachineProvisioning (both PRE and POST), and MachineActivated(PRE), but in all those 4 events i can't get the VCAC object from the WF i've made. after the MachineActivated(PRE+POST) is finished (and thus the machine request appears as Succesfull), i can get ahold of the vcacvm object like expected.

I see the Virtual machine i'm trying to reach by browsing both the vRealize Automation and vRealize Automation Infrastructure plugins (the iaas and the vra servers), but can't from the catalog resource. I've also tried playing with the vCAC:Entity object, but couldn't find a way to get ahold of the vCAC:VM from it.

TLDR , is there another way (or any way at all) to get a vcac vm object during machine provisioning or do i need to suffice working with the VC:VM Object?

Thanks in advance Smiley Happy

Reply
0 Kudos
0 Replies