You can create a VMware Cloud Director cloud account in vRealize Automation to deploy Cloud Director virtual machines using cloud agnostic objects. Cloud Director supports flexible provisioning of network, storage and compute resources, and provides a portal-based experience to manage vCenters and their NSX-T and NSX-V network appliances and associated virtual data centers via a catalog.

The VMware Cloud Director cloud account supports creation of standalone Cloud Director virtual machines with no vApp. Three scenarios for provisioning Cloud Director virtual machines by using Cloud Assembly cloud templates are supported:
  • Virtual machines
  • Virtual machines attached networks
  • Virtual machines with additional disk/s

For more information about working with VMware Cloud Director, including information about setting up multiple servers for high availability, see the official documentation at https://docs.vmware.com/en/VMware-Cloud-Director/index.html.

The VMware Cloud Director cloud account supports up to 1000 virtual machines with vRealize Automation in sustain mode.

The following procedure describes how to set up a VMware Cloud Director cloud account within vRealize Automation Cloud Assembly.

Prerequisites

  • Set up a VMware Cloud Director 10.2.0, 10.2.1, 10.2.2 ,10.3 or 10.3.1 deployment with one or more appropriate organizations.
  • Users specified for this integration must have Organization Administrator privileges to read applicable templates and to create virtual machines as well as to view other resources such as compute policies, disks, virtual data centers, etc. The VCD cloud account for vRealize Automation works within a tenant context in Cloud Director, so you connect to an individual organization in Cloud Director with your tenant credentials. For more information about required credentials, see Credentials required for working with cloud accounts in vRealize Automation.
  • You must configure the appropriate storage, network, image, and flavors, or sizing policy, within your VMware Cloud Director instance and map these objects into vRealize Automation Cloud Assembly either before or after you configure your integration. The following list explains how VMware Cloud Director virtual objects should be mapped to vRealize Automation objects in Cloud Assembly.
    • VMware Cloud Director organization networks (isolated, direct, routed) - map to vRealize Automation networks. No static IP pool can be set for the network adapter.
    • VMware Cloud Director virtual machine sizing policies - map to vRealize Automation flavors.
    • VMware Cloud Director storage policies - map to vRealize Automation storage profiles.
    • VMware Cloud Director images (OVF, ISO boot media) - map to vRealize Automation images. Images can be vApp template or media such as ISO files. If you use ISO then an "empty" virtual machine is created and media is attached as boot media.
    • VMware Cloud Director virtual machines - map to vRealize Automation computes.
    • VMware Cloud Director virtual machines disks - map to vRealize Automation cloud volumes.

    You map these VMware Cloud Director objects to vRealize Automation objects using the options under the Infrastructure > Configure > pages in Cloud Assembly. See the relevant topics under Building your Cloud Assembly resource infrastructure for detailed information about mapping objects in vRealize Automation.

Procedure

  1. Select Infrastructure > Connections > Cloud Accounts and click Add Cloud Account.
  2. Select the VMware Cloud Director cloud account type, and enter a Name and Description.
  3. Enter the appropriate account information required to access the VMware Cloud Director server.
  4. Enter the base URL to use to connect with the VMware Cloud Director server.
  5. Enter an appropriate Username and Password for a valid account that can access the specified Cloud Director instance.
  6. Enter the desired Organization name to use with this integration.
    In vCloud Director, an organization contains users, the vApps that they create, and the resources the vApps use.
  7. Click Validate.
    During validation, you might be asked to accept a certificate. When the connection is validated, you can select additional settings.
  8. If you use tags to support a tagging strategy, enter capability tags. See How do I use tags to manage Cloud Assembly resources and deployments and Creating a tagging strategy.
  9. After you validate, the page displays a list of Cloud Director virtual data centers from which you can select. Select the appropriate data center. This selection determines the Director regions to which you can deploy.
  10. Click Add to add the VMware Cloud Director cloud account to vRealize Automation.

Results

The VMware Cloud Director cloud account is available for configuration in vRealize Automation. The networks associated with the Cloud Director instance are available for configuration on the Cloud Assembly Resources > Networks page. You can set up the appropriate storage profiles and then use the cloud account to create deployments in cloud templates. In addition, ensure that an appropriate project is configured in Cloud Assembly for use with the Cloud Director instance.

What to do next

The VMware Cloud Director cloud account is ready for use in Cloud Assembly cloud templates.

The following is an example cloud template for a basic VMware Cloud Director deployment.

formatVersion: 1
inputs: {}
resources:
  Cloud_Network_1:
    type: Cloud.Network
    properties:
      networkType: existing
      constraints: 
        - tag: net1:isolated
  Cloud_Volume_1:
    type: Cloud.Volume
    properties:
      capacityGb: 2
  Cloud_Machine_1:
    type: Cloud.Machine
    properties:
      image: image1
      flavor: small
      storage: 
        constraints: 
          - tag: storage:development
      attachedDisks:
        - source: '${resource.Cloud_Volume_1.id}'
      networks:
        - network: '${resource.Cloud_Network_1.id}'

The following day 2 actions are supported on deployed VMware Cloud Director virtual machines:

  • Power on
  • Power off
  • Suspend
  • Create snapshot
  • Revert to snapshot
  • Remove snapshot
  • Add disk
  • Remove disk
  • Resize disk (note: only increasing disk size is supported)
  • Resize boot disk

After a blueprint is deployed, users can apply tags on newly provisioned machines in vRealize Automation. These vRealize Automation tags are mapped to VMware Cloud Director metadata which can be retrieved using the VMware Cloud Director API. Users can also tag other vRealize Automation resources, but only machines on the VMware Cloud Director side are updated as it's the only supported type of resource of this feature.

After a blueprint is deployed, users can resize a virtual machine's boot disk. Also regular disks are supported; in this case, customers only need to attach a disk resource to a machine resource. When everything is deployed, you can use the option to "update boot disk" or "update disk" to increase, but not decrease, the size of the desired disk.

After a blueprint is deployed, users can change a virtual machine sizing policy using the resize option using the vRealize Automation flavor configuration Resize option. Once selected, the VMware Cloud Director virtual machine will use the provided sizing policy.

This feature requires that the Default Rights Bundle assigned to the Organization Administrator role contains the "Change compute policies" right, for which internal code is VAPP_EDIT_VM_COMPUTE_POLICY. Then, this right must be activated for the Organization Administrator. Otherwise, the resize operation will fail with an error 403: Either you need some or all of the following rights [VAPP_EDIT_VM_COMPUTE_POLICY] to perform operations.

You can resize the boot disk of a VMware Cloud Director virtual machine as a day 2 operation, by selecting the virtual machine on the Deployments page. However, you must disable Fast provisioning before attempting to resize the boot disk or the following error may occur:

Request timed out after 120 minutes. Please configure project request timeout parameter for long running resource requests.

Note that this requirement applies only to virtual machines created from vApp Template disks. It does not apply to virtual machines created from ISO files.

The following procedure describes how to disable fast provisioning.

  1. Log in to VMware Cloud Director as a system administrator: https://vcd_url/provider with the system user
  2. Click on Organization VDCs.
  3. Select the target organization.
  4. Click on Storage (under Policies).
  5. Disable Fast Provisioning.