Identify resources linked within a Cloud Zone, in a project, and how to delete the deployments to dissociate the cloud zone from the project.
When there are large-scale deployments under vRA it may be difficult to identify the resources in a cloud zone
from the Cloud Assembly UI.
Example API:
https://vra_fqdn/iaas/api/projects?$filter=name%20eq%20'test-project'
Response
{ ...
"name": "test-project",
"description": "",
"id": "<UUID_1>",
"organizationId": "<UUID_2>",
... }
Note: The italicized value is the ID of our project test-project.
Example
https://vra_fqdn/iaas/api/zones?$filter=name%20eq%20'Autolab VC / Autolab'
Response
{ ...
"name": "Autolab VC / Autolab",
"id": "<UUID_3>",
"updatedAt": "2022-08-19",
...}
Note: The italicized value is the ID of our cloud zone Autolab VC / Autolab.
https://vra_fqdn/provisioning/uerp/provisioning/mgmt/compute?$filter=customProperties.__groupResourcePlacementLink%20eq%20 '/provisioning/resources/group-placements/GroupPlacementID'
Note: Group Placement ID is in the format ProjectID-CloudZoneID
<UUID_1>-<UUID_3>
Example API
https://vra_fqdn/provisioning/uerp/provisioning/mgmt/compute?$filter=customProperties.__groupResourcePlacementLink%20eq%20 '/provisioning/resources/group-placements/<UUID_1>-<UUID_3>'
Response
{ ...
"hostName": "UbuntuTest",
"isPublished": true,
"id": "<UUID_4>",
"name": "Cloud_vSphere_Machine_117",
....}
Note: Repeat for all the Resource names identified from Step # 3. These should be searched and deleted from the deployments before attempting to dissociate the cloud zone from the project.
Note: Date, time, and environmental variables may vary depending on your environment.
When a deployment is deleted from vRA, all VMs and resources associated with that deployment are destroyed.