terraform-equinix-fabric-connection
is a minimal Terraform module that
utilizes the Terraform provider for Equinix
to set up an Equinix Fabric L2 connection.
As part of Platform Equinix, your infrastructure can connect with other parties, such as public cloud providers, network service providers, or your own colocation cages in Equinix by defining an Equinix Fabric - software-defined interconnection.
graph LR
subgraph A-side["Origin (A-side)"]
A-side-node1[Equinix Fabric Port /<br> Network Edge Device /<br> Service Token]
end
subgraph Z-side["Destination (Z-side)"]
Z-side-node1[Service Provider /<br> Customer /<br> Colo]
end
A-side-node1 -->|"Equinix Fabric<br>L2 Connection<br>(50Mbps - 10Gbps)"| Z-side-node1
--> NOTE: To establish an Equinix Fabric connection, you need to combine and configure various parameters based on the types of origin and destination. Additionally, you must configure the platform of the service you are connecting to, such as creating an Interconnect Attachment in Google Cloud platform or approving a Direct Connect request in AWS. While this module can be utilized independently, its primary purpose is to be utilized by other service-specific modules. This abstraction simplifies the process and includes all the required configuration on the target platform.
Please click on the link below to explore the available service-specific modules:
Available service-specific modules
Please note that this project is experimental and is supported by the user community. Equinix does not provide support for this project.
To install Terraform, please refer to the official guides at Install Terraform.
You are free to fork, clone, or download this project and modify it as needed for your integrations and deployments.
Additionally, you can use this project as a Terraform module.
To utilize this module in a new project, create a file such as:
# main.tf
provider "equinix" {}
module "equinix_fabric_connection" {
source = "equinix-labs/fabric-connection/equinix"
# required variables
notification_users = ["[email protected]"]
# optional variables
seller_profile_name = "Azure ExpressRoute"
seller_metro_code = "FR"
seller_authorization_key = "Express-Route-Service-Key"
port_name = "Fabric-Port-FR-Pri"
vlan_stag = 1010
named_tag = "PRIVATE"
redundancy_type = "REDUNDANT"
secondary_port_name = "Fabric-Port-FR-Sec"
secondary_vlan_stag = 1020
}
Run terraform init -upgrade
and terraform apply
.
Name | Version |
---|---|
terraform | >= 0.13 |
equinix | ~> 1.14 |
random | 3.6.0 |
Name | Version |
---|---|
equinix | ~> 1.14 |
random | 3.6.0 |
No modules.
Name | Type |
---|---|
equinix_fabric_connection.primary | resource |
equinix_fabric_connection.secondary | resource |
random_string.this | resource |
equinix_fabric_ports.primary | data source |
equinix_fabric_ports.secondary | data source |
equinix_fabric_ports.zside | data source |
equinix_fabric_service_profiles.sp | data source |
Name | Description | Type | Default | Required |
---|---|---|---|---|
notification_users | A list of email addresses used to notify all connection configuration or status changes. One of 'notification_users' or 'notification_users_by_type' is required. This is equivalent to adding a list to 'notification_users_by_type' with the key type ALL. |
list(string) |
n/a | yes |
additional_info | Additional parameters required for some connections. It should be a list of maps containing 'name' and 'value e.g. [{ name='asn' value = '65000'}, { name='ip' value = '192.168.0.1'}] . |
list(object({ |
[] |
no |
connection_type | Defines the connection type like EVPL_VC, EPL_VC, IP_VC, ACCESS_EPL_VC, IA_VC, EVPLAN_VC, EPLAN_VC, IPWAN_VC. If not specified, it will be inferred based on access point types. In cases where the type cannot be identified based on these parameters, the default value will be 'EVPL_VC'. |
string |
"" |
no |
name | Name of the connection resource that will be created. It will be auto-generated if not specified. |
string |
"" |
no |
named_tag | The type of peering to set up in case when connecting to Azure Express Route. One of 'PRIVATE', 'MICROSOFT'. |
string |
"" |
no |
network_edge_id | Unique identifier of the Network Edge virtual device from which the connection would originate. |
string |
"" |
no |
network_edge_interface_id | Applicable with 'network_edge_id', identifier of network interface on a given device, used for a connection. If not specified then first available interface will be selected. |
number |
0 |
no |
network_edge_secondary_id | Unique identifier of the Network Edge virtual device from which the secondary connection would originate. If not specified, and 'network_edge_id' is specified, and 'redundancy_type' is 'REDUNDANT' then primary edge device will be used. |
string |
"" |
no |
network_edge_secondary_interface_id | Applicable with 'network_edge_id' or 'network_edge_secondary_id', identifier of network interface on a given device, used for a connection. If not specified then first available interface will be selected. |
number |
0 |
no |
notification_users_by_type | A map where each key represents a notification type (e.g., 'BANDWIDTH_ALERT', 'ALL') and the value is a list of email addresses. This structure allows for the categorization of email addresses based on the type of notification they should receive. One of 'notification_users_by_type' or 'notification_users' is required. Valid map keys are: ALL, BANDWIDTH_ALERT, CONNECTION_APPROVAL, PROFILE_LIFECYCLE, SALES_REP_NOTIFICATIONS. |
map(list(string)) |
{} |
no |
port_name | Name of the buyer's port from which the primary connection would originate. One of 'port_name', 'network_edge_id' or 'service_token_id' is required. |
string |
"" |
no |
purchase_order_number | Connection's purchase order number to reflect on the invoice. | string |
"" |
no |
redundancy_type | Whether to create a single connection or redundant. Fabric secondary variables will take no effect unless value 'REDUNDANT' is specified. |
string |
"SINGLE" |
no |
secondary_name | Name of the secondary connection that will be created. It will be auto-generated if not specified. |
string |
"" |
no |
secondary_port_name | Name of the buyer's port from which the secondary connection would originate. If not specified, and 'port_name' is specified, and 'redundancy_type' is 'REDUNDANT', then the value of 'port_name' will be used. |
string |
"" |
no |
secondary_seller_authorization_key | Text field used to authorize secondary connection on the provider side. Value depends on a provider service profile used for connection. |
string |
"" |
no |
secondary_seller_metro_code | Metro code where the secondary connection will be created. If not specified then primary connection metro code will be used. |
string |
"" |
no |
secondary_seller_metro_name | Metro name where the secondary connection will be created, i.e. 'Frankfurt', 'Silicon Valley', 'Ashburn'. If not specified then primary connection metro name will be used. |
string |
"" |
no |
secondary_seller_region | The region in which the seller port resides, i.e. 'eu-west-1'. If not specified then primary connection region will be used. |
string |
"" |
no |
secondary_service_token_id | Unique Equinix Fabric key shared with you by a provider that grants you authorization to use their interconnection asset from (a-side) which the secondary connection would originate. Required if 'service_token_id' is specified, and 'redundancy_type' is 'REDUNDANT'. |
string |
"" |
no |
secondary_speed | Speed/Bandwidth to be allocated to the secondary connection - (MB or GB). If not specified then primary connection speed will be used. |
number |
0 |
no |
secondary_speed_unit | DEPRECATED and IGNORED: This variable is no longer used as speed is always assumed to be in MB (megabytes). Specifying this variable will have no effect. |
string |
"" |
no |
secondary_vlan_ctag | VLAN C-Tag/Inner-Tag information for QINQ secondary connections. A numeric character ranging from 2 - 4094. |
number |
0 |
no |
secondary_vlan_stag | VLAN S-Tag/Outer-Tag information for QINQ secondary connections, or VLAN Tag information for DOT1Q. Required if 'secondary_port_name' (A side). A numeric character ranging from 2 - 4094. |
number |
0 |
no |
secondary_zside_service_token_id | Unique Equinix Fabric key shared with you by a provider that grants you authorization to use their interconnection asset to (z-side) which the secondary connection would arrive. |
string |
"" |
no |
seller_authorization_key | Text field used to authorize connection on the provider side. Value depends on a provider service profile used for connection. |
string |
"" |
no |
seller_metro_code | Metro code where the connection will be created. If you do not know the code,'seller_metro_name' can be use instead. |
string |
"" |
no |
seller_metro_name | Metro name where the connection will be created, i.e. 'Frankfurt', 'Silicon Valley', 'Ashburn'. Only required if 'seller_profile_name' is specified and in the absence of 'seller_metro_code'. |
string |
"" |
no |
seller_profile_name | Unique identifier of the service provider's profile. One of 'seller_profile_name' or 'zside_port_name' is required. |
string |
"" |
no |
seller_region | The region in which the seller port resides, i.e. 'eu-west-1'. Required only in cases where you need a specific region of a service provider with several regions per metro. Generally there is only one region per metro, and it will be used the first available region in the metro of the specified seller profile. |
string |
"" |
no |
service_token_id | Unique Equinix Fabric key shared with you by a provider that grants you authorization to use their interconnection asset from (a-side) which the connection would originate. |
string |
"" |
no |
speed | Speed/Bandwidth to be allocated to the connection - (MB or GB). If not specified, it will be used the minimum bandwidth available for the specified seller profile. |
number |
0 |
no |
speed_unit | DEPRECATED and IGNORED: This variable is no longer used as speed is always assumed to be in MB (megabytes). Specifying this variable will have no effect. |
string |
"" |
no |
vlan_ctag | VLAN C-Tag/Inner-Tag information for QINQ connections. A numeric character ranging from 2 - 4094. | number |
0 |
no |
vlan_stag | VLAN S-Tag/Outer-Tag information for QINQ connections, or VLAN Tag information for DOT1Q. Required if 'port_name' (A side). A numeric character ranging from 2 - 4094. |
number |
0 |
no |
zside_port_name | Name of the buyer's port from which the connection would originate the port on the remote side (z-side). Required when destination is another port instead of a service profile. Usually, if you don't have an existing private service profile, this option offers a simple, streamlined way to set up a connection between your own ports. Not compatible with redundant connections. |
string |
"" |
no |
zside_service_token_id | Unique Equinix Fabric key shared with you by a provider that grants you authorization to use their interconnection asset to (z-side) which the connection would arrive. |
string |
"" |
no |
zside_vlan_ctag | VLAN C-Tag/Inner-Tag information for QINQ connections. A numeric character ranging from 2 - 4094. | number |
0 |
no |
zside_vlan_stag | VLAN S-Tag/Outer-Tag information for QINQ connections, or VLAN Tag information for DOT1Q. Required if 'zside_port_name' (Z side). A numeric character ranging from 2 - 4094. |
number |
0 |
no |
Name | Description |
---|---|
primary_connection | Primary connection data. |
secondary_connection | Secondary connection data. |
If you would like to contribute to this module, see the CONTRIBUTING page.
Apache License, Version 2.0. See LICENSE.