Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Page title was updated because corresponding version was renamed.

ProVision-vRA-Plugin

The current plugin release version is: 3.6.21

...

During a typical VM lifecycle, vRealize Automation calls the ProVision IPAM SDK API endpoints that must provide required data as a return value.


Table of Contents

Requirements

ProVision Version - requires ProVision 5.3 or above

VMware Compatibility - vRealize 7.1 or above

Functions

Get Address Space

This workflow returns a list of resource entries (Section: Resource Holder, Category: Address Space) in the ProVision. Each tenant in the vRealize Automation can have one or more address space. The parent of all address spaces is a tenant root resource.

Info
Category Address Space must be added on the ProVision server.

Get IP Ranges

Returns all the IP ranges that that are assigned to the selected address space. These IP Ranges are then assigned to the network profile. Further differentiation within all the ranges is done by specifying the search tags, passed via the custom properties as follows:

...

The values of the properties can be static dynamic. For example there could be a drop down that would list meaningful names to the customers (Floor 1, Floor 2, etc) and this can be translated to ProVision tags via vRealize Action item (which can in turn get this information externally or from vRO configuration element).


Allocate IP address

Allocates one or more IP addresses based on the input properties and returns then to vRealize automation. IP range selection can be further narrowed down by using custom properties (previous Section).

...

Property name

Scope

Example

VirtualMachine.Network.Network#.DNSSuffix

BluePrint

demo.local

VirtualMachine.Network.Network#.PrimaryDNS

BluePrint

10.200.1.11

VirtualMachine.Network.Network#.SecondaryDNS

BluePrint

10.200.1.12

VirtualMachine.Network.Network#.PrimaryWINS

BluePrint

10.1.3.1

VirtualMachine.Network.Network#.SecondaryWINS

BluePrint

10.1.3.2

VirtualMachine.Network.Network#.DNSSearchSuffixes

BluePrint

demo.local, demo2.local

VirtualMachine.Network.Network#. dhcpStaticRoutes121

BluePrint

[{“key”:”10.1.0.0”,”value”: “10.1.0.1”},…]

VirtualMachine.Network.Network#. interfaceMTU26

BluePrint

1500

VirtualMachine.Network.Network#. startDate67

BluePrint

1/1/1900

VirtualMachine.Network.Network#. tftpServerName66

BluePrint

Tftp1

VirtualMachine.Network.Network#. tftpServerAddresses150

BluePrint

[“10.1.1.1”,,”10.1.1.2”]

VirtualMachine.Network.Network#.nextServer

BluePrint

1.1.2.3

VirtualMachine.Network.Network#.autconfigureDNS

BluePrint

true or false

VirtualMachine.Network.Network#.leaseTime

BluePrint

86400                  

Custom.ProVision.SkipHolding

BluePrint

true


Release IP address

Workflow Release is called when vRealize Automation de-provisions the virtual machine. Workflow accepts the IP address that needs to be released and returns it to the free IP Range. Property Custom.ProVision.SkipHolding specifies whether IP address should be released immediately (value ‘true’) or put in a holding tank (undefined/empty or ‘false’).

If the requested NIC index is that of the default interface (default:0) and the DNSZoneId is configured in tenant settings, the corresponding DNS A record is also removed from this zone.

Installation

Please contact support and you will then be able to download the plugin.

Once downloaded, import the plugin into vRealize Orchestrator.


1.1.   

Create REST Host for ProVision in vRealize Orchestrator

First, the API endpoint for the ProVision server needs to be created in vRealize Orchestrator. This is performed by executing the Add a REST Host workflows in the Library/HTTP-REST/Configuration folder.

...


1.2.   

Register ProVision IPAM Endpoint type

In order to be able to create ProVision endpoints, the IPAM Endpoint type needs to be registered in vRrealize Automation. This is performed by running the Add/Update 6Connect IPAM Endpoint workflow located in the 6Connect/IPAM Service Provider/Configuration folder.

...

After this is done, new category will appear in the vRA when creating endpoints. 


1.3.   

Create endpoint

ProVision endpoint can also be created from vRealize Automation web interface, but since custom property is used to specify REST host, it is simpler to use the workflow Add/Update 6Connect IPAM Endpoint.

...

  • Custom.ProVision.RestHOSTId: value contains the GUID of the ProVision REST Host that was selected. This tells the workflows on which ProVision server to execute API calls
  • Custom.ProVision.TenantId: contains the tenant to which the endpoint belongs.


1.4.   

vRO Configuration (ProVision)

vRO configuration is stored in the cofiguration element object which can be accessed by selecting Configurations tab in the vRealize Orchestrator client.  Configuration element is located in Settings/ProVision Settings.

...

Attribute name

Type

Default value

Description

ApiKey

String


Value ApiKey for the ProVision API

ApiSecret

String


Value of ApiSecret for the ProVision API

restHost

RESTHost


REST host for accessing the ProVision API (default)

skipHolding

Boolean

True

Global skip holding setting when releasing the IP address

Credentials

Array


Array of [RestHost, ApiKey, ApiSecret] for multi ProVision environments

AddressSpacesCategorySlug

String

customer

Resource entries category for Address Spaces in the vRealize Automation

AddressSpaceSectionSlug

String

resource-holder

Resource entries section for Address Spaces in the vRealize Automation

VirtualMachineSectionSlug

String

virtual-machine

Section in which the virtual machine resource is created

GatewayTag

String

Gateway

Tag that indicates a gateway IP address

NICTagPrefix

String

NIC:

Tag Prefix for NIC that block is assigned to (NIC Index is appended to this)

tenantSettingsPath

String

Settings/TenantSettings

Location where to store tenant settings

AggregateCategorySlug

String

aggregate

Aggregate category slug

AddressSpaceReservationTag

String

VRA:AS-Reserved

Tag to mark the address space IP blocks

AddressSpaceCategoryName

String

Address Space

The name of the address space category

AggregateCategoryName

String

Aggregate

The name of the aggregate category

TenantRootCategorySlug

String

customer

Tenant root resource category

TenantRootSectionSlug

String

resource-holder

Section of tenant root

TenantRootResourceType

String

entry

Resource type for tenant root

AggregateSectionSlug

String

resource-holder

Aggregate section

AggregateResourceType

String

entry

Aggregate resource type

nsxConfigurationElementPath

String

Settings

Path to the nsx configuration element

nsxConfigurationElementName

String

nsx-configuration-default

Name of the nsx configuration element

dhcpEnablerPropertyName

String

Scc.Vm.Orch.Network

VM property prefix for DHCP enabled property

MaxRetries

Number

3

Maximum number of retries of failed API calls

retrySleepTime

Number

3

Sleep time between API call retries


Section 1.0: ProVision Setup

The process of setting up the tenant, tenant aggregates, address spaces and ip blocks assignment is fully automated through the workflows described below.


1.1.    Initial ProVision Setup

Before new tenants can be provisioned in ProVision, basic configuration workflows need to be executed once per ProVision server and vRO environment.


1.1.1

.

: Tagging the ProVision settings element

In order to simplify searching for the ProVision settings configuration element, the following global tags are added to it:

...

Execute workflow OrchTagConfiguration once per vRO server when performing upgrade existing plugin installation. The workflow will do nothing if tags are already present.


1.1.2

.

: Creating required ProVision objects

In order for multitenancy to function properly, several object need to exist before tenants can be onboarded. This includes:

...

Execute workflow OrchProVisionBaseConfiguration once per ProVision server. If required object are already present, the workflow will do nothing.


Section

1.2: Create New Tenant

Workflow OrchCreateNewTenant creates the following objects on ProVision:

...

The OrchCreateNewTenant can be repeatedly executed with new input values. If the tenant with the same id already exists, it will update the values for RestHostId, DNSZoneId. Any ProVision object thatalready exists will be left intact.


Section

1.3.: Add Aggregate To Tenant

Workflow OrchAddAggregateToTenant adds new aggregate to a tenant.

...

  • Creates specified aggregate block.
  • Assigns it to TenantAggregate resource.
  • If allow duplicates is set to Yes, it creates aggregate even if the same block already exists (same or other tenant)
  • If allow duplicates is set to No, it will skip creation if duplicate is detected in same tenant, otherwise it will report error.


Section

1.4: Create Address Space And Assign Block

Workflow OrchCreateAddressSpaceAndAssignBlock creates new address space resource and then assigns specified block to it. If the address space with the same name already exists, new address block is added to it.

...

In step 3, additional DHCP options can be specified in form of key-value pairs.


Section

1.5: Delete Address Space

Workflow OrchDeleteAddressSpace removes address space and releases all of its blocks back to aggregate.

...

When IP blocks are removed, the reaggregation is performed up to maximum blocksize possible.


Section

1.6: Remove IP Block From Address Space

Workflow OrchRemoveIPBlockFromAddressSpaceunassigns a single IP block from address space and releases it back to parent aggregate.

...

  • tenantId
  • Address space from which to remove: A drop down list displays all of tenant address blocks
  • IPNetwork: A drop down list displays all IP blocks that are assigned to selected address space
  • AddressSpaceId: address space resource id (for non-interactive execution)
  • Address BlockId: address block id (for non-interactive execution)
  • Ignore any leftover assignments and release addresses: If set to Yes, address block is aggregated regardless of assignments. If set to No and there are still IP addresses assigned (apart from network address, broadcast address and gateway), the workflow throws an error


Section

1.7:  Remove Aggregate From Tenant

Workflow OrchRemoveAggregateFromTenant removes an aggregate from a tenant.

...

  • tenantId
  • Aggregate to remove: a drop down list display a list of tenant aggregates
  • Aggregate Id: aggregate block id (for non-interactive execution)
  • Ignore any leftover assignments and release addresses:
    • If set to Yes, aggregate is deleted regardless of assignments.
    • If set to No and there are still IP blocks assigned  the workflow throws an error.


Section

1.8: Delete Tenant

Workflow OrchDeleteTenant removes tenant resources from the ProVision server.

...

Workflow tags  a configuration element under Settings/TenantSettings: TenantSettings-﹤tenantId﹥ with new tag value: CONFIGURATION-STATUS:DELETED

Section 2.0: vRealize Automation Setup

This section summarizes which custom properties and property groups need to be created in vRealize Automation. In order to simplify creation of properties, they are provided in a form of .zip files that can be imported with the help of cloud client application (https://code.vmware.com/tool/cloudclient/4.1.0)

...

Code Block
vra content import --path <path to zip file> --resolution OVERWRITE --precheck ON
Section

2.1: Custom properties

Properties are optional component that needs to be created if more granular selection of IP ranges is needed within one address space (base on the Tenant, BusinessGroup). In the simple scenario, where one address space contains one IP range they are normally not needed. In order for properties to take place, they need to be attached to the blueprint.

...

  • Custom.ProVision.SearchTags.Global
  • Custom.ProVision.SearchTags.Tenant       
  • Custom.ProVision.SearchTags.BluePrint    
  • Custom.ProVision.SearchTags.Mode         
  • Custom.ProVision.SearchTags.Tenant
  • Custom.ProVision.SkipHolding


Section

2.2: Property groups

The following properties need to be created in Administration -﹥ Property dictionary -﹥ Property groups:

  • CustomProVisionTenantPropertyGroup


Section

2.3: Business group properties

The following property must be created on any business group within tenant: Administration -﹥ Users&Groups -﹥ Business Groups:

  • Custom.ProVision.SearchTags.BusinessGroup


Section

2.4: DHCP Subscriptions

DCHP subscription workflows are used to push the DHCP information on NSX during the VM provisioning phase. There are two subscription workflows for this purpose:

...