Recently VMware released PowerCLI 6.5.4 and one of the great enhancements in this new version is the ability to work with VMware Cloud on AWS (VMC), but what does that mean?

As you may know by now, VMware Cloud on AWS is a great new joint offering from VMware and AWS to provide a VMware SDDC in the public cloud.

If we break this down a little and think about how we might manage this with PowerShell we can see that we are in pretty good shape.

PowerCLI has always been able to manage our On-Premises SDDC and as the SDDC deployed in VMware Cloud on AWS is still the same software we have always been able to manage that through PowerCLI as well. With the AWS Tools for Windows PowerShell we have also been able to work with the AWS Services.

So whats new then? Added in PowerCLI 6.5.4 was the ability to manage the VMware Cloud on AWS Service features depicted by the green dotted line in the diagram above. For example, what if i wanted to list all my SDDCs available to me or what if i wanted to automate the creation of a new SDDC or what if I wanted to provision or de-provision a new AWS bare metal instance into my SDDC, well now you can, and all from the same shell.

PowerCLI 6.5.4 VMware Cloud on AWS Module

As mentioned in the VMware PowerCLI 6.5.4 Release Blog Post we now have a new module that allows us to work with the VMware Cloud on AWS service, it gives us 3 new cmdlets:

Connect-Vmc –This cmdlet establishes a connection to a VMware Cloud on AWS server.

Disconnect-Vmc – This cmdlet closes the connection to the servers specified by the Server parameter.

Get-VmcService – This cmdlet retrieves PSObject objects that represent a proxy to a VMware Cloud on AWS API service, it essentially allows us to access 100% of the public VMware Cloud on AWS API.

Whilst these are a great start you really need to work with the Get-VMCService and the properties and methods it brings back to really automate the features. Luckily William Lam, Brian Graf and I have already been working with this cmdlet and wanted to make it easier to use and also provide examples of how to use the cmdlet to work with any of the features available in the VMware Cloud on AWS API now and in the future…..

VMware Cloud on AWS simple functions

This module adds more functions to enable you to easier work with VMware Cloud on AWS, the included functions so far are:

Get-VMCCommand – Returns all cmdlets for VMware Cloud on AWS in both this module and the VMware official module.

Connect-VMCVIServer – This Cmdlet pulls the default SDDC credentials and connects to your VMC vCenter Server to ease the connection from service to SDDC.

Get-VMCOrg – Returns the Orgs that you have available in VMware Cloud on AWS.

Get-VMCSDDC – Returns all of the SDDCs that you have available to you in VMware Cloud on AWS.

Get-VMCSDDCDefaultCredential – Returns the default credential for a given SDDC.

Get-VMCSDDCPublicIP – Returns your Public IPs for a given SDDC.

Get-VMCSDDCVersion – Returns the SDDC Version.

Get-VMCTask – Returns all of the VMC Tasks.

Get-VMCVMHost – Returns the Host information within VMware Cloud on AWS.

Clearly these are just the first set we have worked on as an example, more functions will be added in the future and probably have been by the time you read this post!

An example of some of these being used is below:

How do I get the module?

The module is available in the PowerShell Gallery here so installing could not be simpler, but of course make sure you have PowerCLI 6.5.4 installed first otherwise this module wont do you much good!

PS> Install-Module -Name VMware.VMC -Scope User

How do I contribute to the module?

This module is also available in Github as part of the vmware/PowerCLI-Example-Scripts repo so please do clone the repo, edit the module and contribute back to make this easy for everyone!

-Alan

Share this: Email

Print

Twitter

Facebook

Reddit

