How to

Automating VMware Cloud on AWS One Host SDDC Deployments

The latest release of VMware Cloud on AWS introduces a brand-new deployment configuration. We can now deploy an SDDC which consists of a single host! This is exciting for many reasons, but biggest reason for me is being able to access all the APIs without occupying the standard minimum SDDC footprint of four hosts.

More information on the One Host release is available here: VMware Cloud on AWS – Single Host Access

We’re going to take a quick look at how we can quickly and easily deploy one of these 1 host SDDCs through the Developer Center API Explorer, PowerCLI, and Datacenter CLI (DCLI).

AWS Customer Account Linking

If this is the first time you’re deploying an SDDC, you will need to link your AWS account to the VMware Cloud on AWS service. This linking allows us to do many things but, for the purpose of an SDDC deployment, it will allow us to connect our SDDC to our existing AWS VPC.

The easiest way to create this link is by logging in to the VMware Cloud on AWS Cloud Console, heading to the ‘Developer Center’ tab from the top menu, then the ‘API Explorer’ sub-tab. We will then want to expand the ‘AWS Account Connection Operations’ section, followed by also expanding the ‘GET /orgs/{org}/account-link’ section. After verifying the ‘org’ parameter already has a value set, click the ‘Execute’ button.

VMWonAWS - Account Linking API Usage

We’ll want to then copy the URL associated with the ‘template_execution_url’ and paste it into our browser of choice. This URL take us to AWS’ CloudFormation service and run through a template that will configure the account linking on our behalf.

VMWonAWS - Account Linking API Usage

We’re now ready to start deploying our SDDC with the method of our choice!

Developer Center API Explorer

The Developer Center continues to be one of my favorite manners of learning, exploring, and even using the VMware Cloud on AWS APIs. Let’s start with deploying a one host SDDC with the built in API Explorer.

If you’re not still in the API Explorer from the previous section, the API Explorer can be found by logging into the VMware Cloud on AWS Cloud Console, selecting the ‘Developer Center’ tab from the top menu, then selecting the ‘API Explorer’ sub-tab.
Now that we’re in the API Explorer, we’ll want to browse for the ‘SDDCs’ section and expand that. We’ll then also want to expand the following top section labeled ‘POST /orgs/{org}/sddcs’. We’ll see the ‘org’ parameter already has our Org Id filled in as well as a blank ‘sddcConfig’ value. We can populate that value with an example JSON body containing empty values by clicking on the ‘AwsSddcConfig’ link in the ‘Data Type’ column.

  • connected_account_id: Enter the AWS account this SDDC should be connected to.
    Note: This is the ID for the account which can be pulled from the API with the following:
    Method: GET /orgs/{org}/account-link/connected-accounts
    Property: ID
  • customer_subnet_ids: Enter the desired subnet ID for VPC traffic.
    Note: This is the ID for the VPC subnet which can be pulled from the API with the following:
    Method: GET /orgs/{org}/account-link/compatible-subnets
    Property: subnet_id
  • deployment_type: Enter whether this SDDC should be contained with a singular availability zone or across multiple availability zones.
    Note: one host SDDCs can only be of a type ‘SingleAZ’
  • name: Enter the desired name of the SDDC
  • numOfHosts: Enter the number of desired hosts, in this case: 1
  • provider: Enter the provider, which would be ‘AWS’
  • region: Enter the desired region. (Case sensitive format example: US_WEST_2)
  • sddc_template_id: Enter the SDDC Template ID
  • sddc_type: Enter the SDDC type
  • sddc_domain: Enter the desired SSO domain (Default: vmc.local)
  • vpc_cidr: Enter the desired subnet to use that corresponds with preferred management subnet (Default: 10.2.0.0/16)
  • vxlan_subnet: Enter a VXLAN IP subnet to be used.

A minimal sddcConfig would look like the following:

Click ‘Execute’ and the response should be a task object including the details for your newly deploying SDDC!

PowerCLI Deployment

PowerCLI has the ability to interact with the VMware Cloud on AWS APIs through a low-level, API access only, module. The following script makes the process of deploying a single node SDDC easy and straightforward. Download the sample script below, update lines 9 through 12 with values for your environment, and run the script!

Datacenter CLI Deployment

DCLI also has the ability to interact with the VMware Cloud on AWS APIs. There’s also a script which allows DCLI to easily create a single node SDDC. Download the sample script below, update line 10 to point to the location of JQ, also update lines 13 through 15 with values for your environment, and run the script!

Summary

The latest update to VMware Cloud on AWS brings a great new way to access all the features, services, and APIs the service has available, just in a smaller footprint. These one host SDDCs can be deployed and managed the same way as standard SDDCs. This blog post took a look at how to use the RESTful API as well as two CLIs (PowerCLI and DCLI) to deploy this new configuration.

Let us know in the comments what your preferred method of deployment is!