Azure Network Circuit Connection

This page shows how to write Terraform and Azure Resource Manager for Network Circuit Connection and write them securely.

azurerm_express_route_circuit_connection (Terraform)

The Circuit Connection in Network can be configured in Terraform with the resource name azurerm_express_route_circuit_connection. The following sections describe how to use the resource and its parameters.

Example Usage from GitHub

An example could not be found in GitHub.

Review your Terraform file for Azure best practices

Shisho Cloud, our free checker to make sure your Terraform configuration follows best practices, is available (beta).

Parameters

The following arguments are supported:

  • name - (Required) The name which should be used for this Express Route Circuit Connection. Changing this forces a new Express Route Circuit Connection to be created.

  • peering_id - (Required) The ID of the Express Route Circuit Private Peering that this Express Route Circuit Connection connects with. Changing this forces a new Express Route Circuit Connection to be created.

  • peer_peering_id - (Required) The ID of the peered Express Route Circuit Private Peering. Changing this forces a new Express Route Circuit Connection to be created.

  • address_prefix_ipv4 - (Required) The IPv4 address space from which to allocate customer address for global reach. Changing this forces a new Express Route Circuit Connection to be created.


  • authorization_key - (Optional) The authorization key which is associated with the Express Route Circuit Connection.

  • address_prefix_ipv6 - (Optional) The IPv6 address space from which to allocate customer addresses for global reach.

-> NOTE: address_prefix_ipv6 cannot be set when ExpressRoute Circuit Connection with ExpressRoute Circuit based on ExpressRoute Port.

In addition to the Arguments listed above - the following Attributes are exported:

  • id - The ID of the Express Route Circuit Connection.

Explanation in Terraform Registry

Manages an Express Route Circuit Connection.

Tips: Best Practices for The Other Azure Network Resources

In addition to the azurerm_network_security_group, Azure Network has the other resources that should be configured for security reasons. Please check some examples of those resources and precautions.

risk-label

azurerm_network_security_group

Ensure to disable RDP port from the Internet

It is better to disable the RDP port from the Internet. RDP access should not be accepted from the Internet (*, 0.0.0.0, /0, internet, any), and consider using the Azure Bastion Service.

risk-label

azurerm_network_security_rule

Ensure to set a more restrictive CIDR range for ingress from the internet

It is better to set a more restrictive CIDR range not to use very broad subnets. If possible, segments should be divided into smaller subnets.

risk-label

azurerm_network_watcher_flow_log

Ensure to enable Retention policy for flow logs and set it to enough duration

It is better to enable a retention policy for flow logs. Flow logs show us all network activity in the cloud environment and support us when we face critical incidents.

Review your Azure Network settings

In addition to the above, there are other security points you should be aware of making sure that your .tf files are protected in Shisho Cloud.

Microsoft.Network/expressRouteCircuits/peerings/connections (Azure Resource Manager)

The expressRouteCircuits/peerings/connections in Microsoft.Network can be configured in Azure Resource Manager with the resource name Microsoft.Network/expressRouteCircuits/peerings/connections. The following sections describe how to use the resource and its parameters.

Example Usage from GitHub

An example could not be found in GitHub.

Parameters

  • name required - string
  • type required - string
  • apiVersion required - string
  • properties required
      • expressRouteCircuitPeering optional
          • id required - string

            Resource ID.

      • peerExpressRouteCircuitPeering optional
          • id required - string

            Resource ID.

      • addressPrefix optional - string

        /29 IP address space to carve out Customer addresses for tunnels.

      • authorizationKey optional - string

        The authorization key.

      • ipv6CircuitConnectionConfig optional
          • addressPrefix optional - string

            /125 IP address space to carve out customer addresses for global reach.

Frequently asked questions

What is Azure Network Circuit Connection?

Azure Network Circuit Connection is a resource for Network of Microsoft Azure. Settings can be wrote in Terraform.