Automated deployment of vRealize Automation 8.x via Powershell – Part 1

For my work, I regularly need to deploy a fresh vRA Environment, either to test with a specific (older) version or new beta release. Although the Deployment of vRA is relatively easy, it always takes me more time than I like, so I decided to throw in some extra time and automate the deployment of vRSLCM, VIDM and VRA. There are several options to do the automation, but it mainly comes down to scripting around the available API’s.

I decided to use PowerShell for scripting since I’m most familiar with this. Bear in mind that I am not a programmer, so some parts of my scripts may be further optimized and need additional error handling.

In Part 1 of this blog I will start with the Automated Deployment of vRSLCM.

My manual deployment workflow consists of downloading the Easy Installer ISO to my local drive. Then mount the ISO and run the installation. During the installation the ova files for VIDM and VRA are copied to the vRSLCM server.

For an automated deployment you cannot use the installer and you must make use of the vRSLCM ova that is inside the ISO file. This means the VIDM and VRA OVA files must be imported after deployment. Within vRSLCM there are 3 options to import install or upgrade files;

  • Copy the files to a directory on the VRSLCM Server
  • Copy the files from NFS
  • Download the files from MyVMware

Since I have a NAS in my homelab that can serve SMB and NFS, I decided to (make it optional to) copy both vidm and vra ova files to vRSLCM or a SMB/NFS share in the script, so it can be picked up later during vRSLCM configuration in Part 2.

The deployment script itself is straight forward. You only need to configure the path to the Easy Installer iso and your specific environment variables. In outline the script does the following:

  • Mount the Easy Installer ISO.
  • Set the ovf properties.
  • Deploy vRSLCM with the Import-VApp cmdlet.
  • Start the vRSLCM VM.
  • (Optionally) Copy the VIDM and vRA ova files to your vRSLCM Appliance or a NFS share.
  • Unmounts the Easy Installer iso.

You can find the latest version of the script “vRSLCM-Deployments.ps1” in my [Github] repository.

By default the script copies the vidm and vra .ova files to the vRSLCM appliance by means of SCP. To make this work, you have to install and import the [Posh-SSH] Powershell module. File transfer can also be done with the [BitsTransfer] cmdlet. It’s up to your enviroment and preferences what to use.

With the variables below you can configure the copy options:

$copyVIDMOVA = $true | $false
$copyvRAOVA = $true | $false
$ovaDestinationType = "VRSLCM" | "NFS"
$nfsshare = "<Path to SMB/NFS share>"

After successful deployment, have a look at Part 2 which is all about the automated configuration of vRSLCM and the deployment of VIDM and vRA.


Henk Engelsman

Leave a Reply

Your email address will not be published. Required fields are marked *

Post comment