As a cloud administrator, you can leverage the Microsoft Azure plug-in to provision plug-in based virtual networks to support your infrastructure needs. You can also use allocation helpers to provide allocation logic for your virtual networks.

You can easily configure your Azure virtual networks to support your infrastructure needs. VMware Aria Automation supports creating virtual networks, virtual network peerings, network interfaces, and more.

Virtual network properties

The following properties are required to provision plug-in based virtual networks for Microsoft Azure.

Property Description
name The plugin-specific name for the virtual network.

You can use the same value for the virtual_network_name property.

virtual_network_name The name of the virtual network.
account The Microsoft Azure cloud account for account regions to which your team deploys cloud templates.

See Create a Microsoft Azure cloud account in VMware Aria Automation for more information.

location The region where the virtual network will be deployed.
address_space An array of IP address ranges that can be used by subnets of the virtual network.
resource_group_name The name of the resource group.

You must create the resource group in your Azure portal.

Provision an Azure virtual network

The following template shows how you might provision a basic Azure virtual network.

formatVersion: 1
inputs: {}
resources:
  Idem_AZURE_NETWORK_VIRTUAL_NETWORKS_1:
    type: Idem.AZURE.NETWORK.VIRTUAL_NETWORKS
    properties:
      name: azure-network
      account: azure-account
      location: eastus
      address_space:
        - 10.0.0.0/26
      resource_group_name: validate_azure_rg
      virtual_network_name: azure-vnet
      tags:
        a: b

Provision Azure virtual network peerings

The following template shows how you might provision virtual network peerings. In this example, you create a network peering between two networks with different address spaces.

formatVersion: 1
inputs:
  resource_group_name:
    type: string
    title: Resource Group Name
  suffix:
    type: string
    title: ''
resources:
  Allocations_Compute_1:
    type: Allocations.Compute
    properties: {}
  Idem_AZURE_NETWORK_VIRTUAL_NETWORKS_1:
    type: Idem.AZURE.NETWORK.VIRTUAL_NETWORKS
    properties:
      name: net-1-doc-${input.suffix}
      virtual_network_name: net-1-doc-${input.suffix}
      resource_group_name: ${input.resource_group_name}
      account: azure-account
      location: ${resource.Allocations_Compute_1.selectedRegion.id}
      virtual_network_peerings:
      address_space:
        - 10.10.0.0/24
      subnets:
        - name: subnet-1-doc-${input.suffix}
          address_prefix: 10.10.0.0/24
  Idem_AZURE_NETWORK_VIRTUAL_NETWORKS_2:
    type: Idem.AZURE.NETWORK.VIRTUAL_NETWORKS
    properties:
      name: net-2-doc-${input.suffix}
      virtual_network_name: net-2-doc-${input.suffix}
      resource_group_name: ${input.resource_group_name}
      account: azure-account
      location: ${resource.Allocations_Compute_1.selectedRegion.id}
      address_space:
        - 10.0.0.0/24
      subnets:
        - name: subnet-2-doc-${input.suffix}
          address_prefix: 10.0.0.0/24
  Idem_AZURE_NETWORK_VIRTUAL_NETWORK_PEERINGS_1:
    type: Idem.AZURE.NETWORK.VIRTUAL_NETWORK_PEERINGS
    properties:
      name: peering-doc-${input.suffix}
      virtual_network_peering_name: peering-doc-${input.suffix}
      resource_group_name: ${input.resource_group_name}
      account: azure-account
      virtual_network_name: ${resource.Idem_AZURE_NETWORK_VIRTUAL_NETWORKS_1.virtual_network_name}
      remote_virtual_network:
        id: ${resource.Idem_AZURE_NETWORK_VIRTUAL_NETWORKS_2.resource_id}
      use_remote_gateways: false
      allow_virtual_network_access: false

Provision an Azure network interface

The following template shows how you might provision a network interface. Before you deploy this template, complete the following prerequisites:

  1. Create a network in your chosen region with a range of 10.10.0.0/25 and a subnetwork named "default" with range of 10.10.0.0/27.
  2. Create a public IP address.
formatVersion: 1
inputs: {}
resources:
  Idem_AZURE_NETWORK_NETWORK_INTERFACES_1:
    type: Idem.AZURE.NETWORK.NETWORK_INTERFACES
    properties:
      name: validate_azure_nic_create
      account: azure-account
      location: eastus
      ip_configurations:
        - name: validate_azure_ipc
          private_ip_address_allocation: Static
          subnet_id: /subscriptions/svpvln45-brk0-mzca-7yxh-dla7h19zxyn3/resourceGroups/validate_azure_rg/providers/Microsoft.Network/virtualNetworks/validate_azure_network/subnets/default
          primary: true
          private_ip_address_version: IPv4
          private_ip_address: 10.10.0.24
          public_ip_address_id: /subscriptions/svpvln45-brk0-mzca-7yxh-dla7h19zxyn3/resourceGroups/validate_azure_rg/providers/Microsoft.Network/publicIPAddresses/validate_azure_ip
      resource_group_name: validate_azure_rg
      network_interface_name: validate_azure_nic_create
      enable_accelerated_networking: true
      dns_settings:
        dns_servers:
          - 168.63.129.16
        internal_dns_name_label: test-dns-label