From a87fda2488474e9f76b49190b5a9b3304c8a684d Mon Sep 17 00:00:00 2001 From: Srushti Patel <137830748+srushti-patl@users.noreply.github.com> Date: Mon, 27 Nov 2023 08:58:56 -0800 Subject: [PATCH] =?UTF-8?q?CXF-80887=20Adding=20Cloud=20Router=20Connectio?= =?UTF-8?q?n=20module=20&=20AWS,=20Port,=20Azure-Re=E2=80=A6=20(#7)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * CXF-80887 Adding Cloud Router Connection module & AWS, Port, Azure-Redundant connections examples * CXF-80887 fixing FCR connection module & examples * CXF-80887 fixing connection module & examples scripts * CXF-80887 fixing changes for vlang tags and misc. * CXF-80887 Adding Azure,GCP,Oracle,sp, wan connections example scripts and README.md files --- .../cloud-router-2-aws-connection/README.md | 0 .../cloud-router-2-aws-connection/main.tf | 37 +++ .../cloud-router-2-aws-connection/outputs.tf | 3 + .../terrafor.tfvars.example | 19 ++ .../variables.tf | 88 ++++++++ .../cloud-router-2-azure-connection/README.md | 0 .../cloud-router-2-azure-connection/main.tf | 36 +++ .../outputs.tf | 3 + .../terraform.tfvars.example | 17 ++ .../variables.tf | 73 ++++++ .../README.md | 0 .../main.tf | 42 ++++ .../outputs.tf | 6 + .../terraform.tfvars.example | 21 ++ .../variables.tf | 91 ++++++++ .../cloud-router-2-gcp-connection/README.md | 0 .../cloud-router-2-gcp-connection/main.tf | 36 +++ .../cloud-router-2-gcp-connection/outputs.tf | 3 + .../terraform.tfvars.example | 17 ++ .../variables.tf | 73 ++++++ .../README.md | 0 .../cloud-router-2-oracle-connection/main.tf | 37 +++ .../outputs.tf | 3 + .../terraform.tfvars.example | 18 ++ .../variables.tf | 75 ++++++ .../cloud-router-2-port-connection/README.md | 0 .../cloud-router-2-port-connection/main.tf | 34 +++ .../cloud-router-2-port-connection/outputs.tf | 3 + .../terraform.tfvars.example | 15 ++ .../variables.tf | 61 +++++ .../README.md | 0 .../main.tf | 34 +++ .../outputs.tf | 3 + .../terraform.tfvars.example | 15 ++ .../variables.tf | 61 +++++ .../cloud-router-2-wan-connection/README.md | 0 .../cloud-router-2-wan-connection/main.tf | 32 +++ .../cloud-router-2-wan-connection/outputs.tf | 3 + .../terraform.tfvars.example | 13 ++ .../variables.tf | 50 ++++ modules/cloud-router-2-aws/README.md | 45 ---- modules/cloud-router-2-aws/main.tf | 55 ----- modules/cloud-router-2-aws/terraform.tf | 7 - .../terraform.tfvars.example | 22 -- modules/cloud-router-2-aws/variables.tf | 24 -- .../single-connection/README.md | 44 ---- .../single-connection/main.tf | 56 ----- .../single-connection/terraform.tf | 7 - .../terraform.tfvars.example | 18 -- .../single-connection/variables.tf | 18 -- .../two-connections/README.md | 47 ---- .../two-connections/main.tf | 109 --------- .../two-connections/terraform.tf | 7 - .../two-connections/terraform.tfvars.example | 19 -- .../two-connections/variables.tf | 19 -- modules/cloud-router-2-gcp/README.md | 40 ---- modules/cloud-router-2-gcp/main.tf | 56 ----- modules/cloud-router-2-gcp/terraform.tf | 7 - .../terraform.tfvars.example | 19 -- modules/cloud-router-2-gcp/variables.tf | 21 -- modules/cloud-router-2-ipwan/README.md | 39 ---- modules/cloud-router-2-ipwan/main.tf | 40 ---- modules/cloud-router-2-ipwan/terraform.tf | 7 - .../terraform.tfvars.example | 12 - modules/cloud-router-2-ipwan/variables.tf | 18 -- modules/cloud-router-2-oracle/README.md | 44 ---- modules/cloud-router-2-oracle/main.tf | 54 ----- modules/cloud-router-2-oracle/terraform.tf | 7 - .../terraform.tfvars.example | 17 -- modules/cloud-router-2-oracle/variables.tf | 17 -- modules/cloud-router-2-port/README.md | 38 ---- modules/cloud-router-2-port/main.tf | 48 ---- modules/cloud-router-2-port/terraform.tf | 7 - .../terraform.tfvars.example | 17 -- modules/cloud-router-2-port/variables.tf | 17 -- .../cloud-router-2-service-profile/README.md | 38 ---- .../cloud-router-2-service-profile/main.tf | 50 ---- .../terraform.tf | 7 - .../terraform.tfvars.example | 16 -- .../variable.tf | 16 -- modules/cloud-router-connection/main.tf | 179 +++++++++++++++ modules/cloud-router-connection/outputs.tf | 6 + modules/cloud-router-connection/variables.tf | 105 +++++++++ modules/cloud-router-multi-cloud/README.md | 109 --------- modules/cloud-router-multi-cloud/main.tf | 213 ------------------ modules/cloud-router-multi-cloud/terraform.tf | 7 - .../terraform.tfvars.example | 79 ------- modules/cloud-router-multi-cloud/variables.tf | 71 ------ modules/port-2-google/README.md | 51 ----- modules/port-2-google/terraform.tf | 7 - modules/port-2-ibm2/README.md | 52 ----- modules/port-2-ibm2/terraform.tf | 7 - modules/port-2-ibm2/variables.tf | 20 -- 93 files changed, 1312 insertions(+), 1765 deletions(-) create mode 100644 examples/cloud-router-2-aws-connection/README.md create mode 100644 examples/cloud-router-2-aws-connection/main.tf create mode 100644 examples/cloud-router-2-aws-connection/outputs.tf create mode 100644 examples/cloud-router-2-aws-connection/terrafor.tfvars.example create mode 100644 examples/cloud-router-2-aws-connection/variables.tf create mode 100644 examples/cloud-router-2-azure-connection/README.md create mode 100644 examples/cloud-router-2-azure-connection/main.tf create mode 100644 examples/cloud-router-2-azure-connection/outputs.tf create mode 100644 examples/cloud-router-2-azure-connection/terraform.tfvars.example create mode 100644 examples/cloud-router-2-azure-connection/variables.tf create mode 100644 examples/cloud-router-2-azure-redundant-connection/README.md create mode 100644 examples/cloud-router-2-azure-redundant-connection/main.tf create mode 100644 examples/cloud-router-2-azure-redundant-connection/outputs.tf create mode 100644 examples/cloud-router-2-azure-redundant-connection/terraform.tfvars.example create mode 100644 examples/cloud-router-2-azure-redundant-connection/variables.tf create mode 100644 examples/cloud-router-2-gcp-connection/README.md create mode 100644 examples/cloud-router-2-gcp-connection/main.tf create mode 100644 examples/cloud-router-2-gcp-connection/outputs.tf create mode 100644 examples/cloud-router-2-gcp-connection/terraform.tfvars.example create mode 100644 examples/cloud-router-2-gcp-connection/variables.tf create mode 100644 examples/cloud-router-2-oracle-connection/README.md create mode 100644 examples/cloud-router-2-oracle-connection/main.tf create mode 100644 examples/cloud-router-2-oracle-connection/outputs.tf create mode 100644 examples/cloud-router-2-oracle-connection/terraform.tfvars.example create mode 100644 examples/cloud-router-2-oracle-connection/variables.tf create mode 100644 examples/cloud-router-2-port-connection/README.md create mode 100644 examples/cloud-router-2-port-connection/main.tf create mode 100644 examples/cloud-router-2-port-connection/outputs.tf create mode 100644 examples/cloud-router-2-port-connection/terraform.tfvars.example create mode 100644 examples/cloud-router-2-port-connection/variables.tf create mode 100644 examples/cloud-router-2-service-profile-connection/README.md create mode 100644 examples/cloud-router-2-service-profile-connection/main.tf create mode 100644 examples/cloud-router-2-service-profile-connection/outputs.tf create mode 100644 examples/cloud-router-2-service-profile-connection/terraform.tfvars.example create mode 100644 examples/cloud-router-2-service-profile-connection/variables.tf create mode 100644 examples/cloud-router-2-wan-connection/README.md create mode 100644 examples/cloud-router-2-wan-connection/main.tf create mode 100644 examples/cloud-router-2-wan-connection/outputs.tf create mode 100644 examples/cloud-router-2-wan-connection/terraform.tfvars.example create mode 100644 examples/cloud-router-2-wan-connection/variables.tf delete mode 100644 modules/cloud-router-2-aws/README.md delete mode 100644 modules/cloud-router-2-aws/main.tf delete mode 100644 modules/cloud-router-2-aws/terraform.tf delete mode 100644 modules/cloud-router-2-aws/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-aws/variables.tf delete mode 100644 modules/cloud-router-2-azure/single-connection/README.md delete mode 100644 modules/cloud-router-2-azure/single-connection/main.tf delete mode 100644 modules/cloud-router-2-azure/single-connection/terraform.tf delete mode 100644 modules/cloud-router-2-azure/single-connection/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-azure/single-connection/variables.tf delete mode 100644 modules/cloud-router-2-azure/two-connections/README.md delete mode 100644 modules/cloud-router-2-azure/two-connections/main.tf delete mode 100644 modules/cloud-router-2-azure/two-connections/terraform.tf delete mode 100644 modules/cloud-router-2-azure/two-connections/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-azure/two-connections/variables.tf delete mode 100644 modules/cloud-router-2-gcp/README.md delete mode 100644 modules/cloud-router-2-gcp/main.tf delete mode 100644 modules/cloud-router-2-gcp/terraform.tf delete mode 100644 modules/cloud-router-2-gcp/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-gcp/variables.tf delete mode 100644 modules/cloud-router-2-ipwan/README.md delete mode 100644 modules/cloud-router-2-ipwan/main.tf delete mode 100644 modules/cloud-router-2-ipwan/terraform.tf delete mode 100644 modules/cloud-router-2-ipwan/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-ipwan/variables.tf delete mode 100644 modules/cloud-router-2-oracle/README.md delete mode 100644 modules/cloud-router-2-oracle/main.tf delete mode 100644 modules/cloud-router-2-oracle/terraform.tf delete mode 100644 modules/cloud-router-2-oracle/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-oracle/variables.tf delete mode 100644 modules/cloud-router-2-port/README.md delete mode 100644 modules/cloud-router-2-port/main.tf delete mode 100644 modules/cloud-router-2-port/terraform.tf delete mode 100644 modules/cloud-router-2-port/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-port/variables.tf delete mode 100644 modules/cloud-router-2-service-profile/README.md delete mode 100644 modules/cloud-router-2-service-profile/main.tf delete mode 100644 modules/cloud-router-2-service-profile/terraform.tf delete mode 100644 modules/cloud-router-2-service-profile/terraform.tfvars.example delete mode 100644 modules/cloud-router-2-service-profile/variable.tf create mode 100644 modules/cloud-router-connection/main.tf create mode 100644 modules/cloud-router-connection/outputs.tf create mode 100644 modules/cloud-router-connection/variables.tf delete mode 100644 modules/cloud-router-multi-cloud/README.md delete mode 100644 modules/cloud-router-multi-cloud/main.tf delete mode 100644 modules/cloud-router-multi-cloud/terraform.tf delete mode 100644 modules/cloud-router-multi-cloud/terraform.tfvars.example delete mode 100644 modules/cloud-router-multi-cloud/variables.tf delete mode 100644 modules/port-2-google/README.md delete mode 100644 modules/port-2-google/terraform.tf delete mode 100644 modules/port-2-ibm2/README.md delete mode 100644 modules/port-2-ibm2/terraform.tf delete mode 100644 modules/port-2-ibm2/variables.tf diff --git a/examples/cloud-router-2-aws-connection/README.md b/examples/cloud-router-2-aws-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-aws-connection/main.tf b/examples/cloud-router-2-aws-connection/main.tf new file mode 100644 index 00000000..d6979779 --- /dev/null +++ b/examples/cloud-router-2-aws-connection/main.tf @@ -0,0 +1,37 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_aws_connection" { + source = "../../modules/cloud-router-connection" + + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + additional_info = [{ key = "accessKey", value = var.aws_access_key }, { key = "secretKey", value = var.aws_secret_key }] + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_fcr_uuid = var.aside_fcr_uuid + aside_ap_type = var.aside_ap_type + + #Zside + zside_ap_type = var.zside_ap_type + zside_ap_authentication_key = var.zside_ap_authentication_key + zside_ap_profile_type = var.zside_ap_profile_type + zside_location = var.zside_location + zside_seller_region = var.zside_seller_region + zside_fabric_sp_name = var.zside_fabric_sp_name +} diff --git a/examples/cloud-router-2-aws-connection/outputs.tf b/examples/cloud-router-2-aws-connection/outputs.tf new file mode 100644 index 00000000..ec5d88bd --- /dev/null +++ b/examples/cloud-router-2-aws-connection/outputs.tf @@ -0,0 +1,3 @@ +output "module_output" { + value = module.cloud_router_aws_connection.primary_connection_id +} diff --git a/examples/cloud-router-2-aws-connection/terrafor.tfvars.example b/examples/cloud-router-2-aws-connection/terrafor.tfvars.example new file mode 100644 index 00000000..28ee1a01 --- /dev/null +++ b/examples/cloud-router-2-aws-connection/terrafor.tfvars.example @@ -0,0 +1,19 @@ +equinix_client_id = "" +equinix_client_secret = "" + +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +aside_fcr_uuid = "" +connection_name = "fcr_2_aws" +connection_type = "IP_VC" +bandwidth = 50 +aside_ap_type = "CLOUD_ROUTER" +zside_ap_type = "SP" +zside_ap_authentication_key = "" +zside_ap_profile_type = "L2_PROFILE" +zside_location = "SV" +zside_seller_region = "us-west-1" +zside_fabric_sp_name = "AWS Direct Connect" +aws_access_key = "" +aws_secret_key = "" diff --git a/examples/cloud-router-2-aws-connection/variables.tf b/examples/cloud-router-2-aws-connection/variables.tf new file mode 100644 index 00000000..6a1322fe --- /dev/null +++ b/examples/cloud-router-2-aws-connection/variables.tf @@ -0,0 +1,88 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + default = "" + type = string +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string + +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} +variable "zside_ap_authentication_key" { + description = "Authentication key for provider based connections" + type = string + default = "" +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_ap_profile_type" { + description = "Service profile type - L2_PROFILE, L3_PROFILE, ECIA_PROFILE, ECMC_PROFILE" + type = string + default = "L2_PROFILE" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} +variable "zside_fabric_sp_name" { + description = "Equinix Service Profile Name" + type = string + default = "" +} +variable "zside_seller_region" { + description = "Access point seller region" + type = string + default = "" +} +variable "aws_access_key" { + description = "AWS Access Key from the AWS Console" + type = string + default = null +} +variable "aws_secret_key" { + description = "AWS Secret Key from the AWS Console" + type = string + default = null +} + +variable "additional_info" { + description = "Additional parameters required for some service profiles. It should be a list of maps containing 'key' and 'value e.g. `[{ key='asn' value = '65000'}, { key='ip' value = '192.168.0.1'}]`" + type = list(object({ key = string, value = string })) + default = [] +} diff --git a/examples/cloud-router-2-azure-connection/README.md b/examples/cloud-router-2-azure-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-azure-connection/main.tf b/examples/cloud-router-2-azure-connection/main.tf new file mode 100644 index 00000000..5be5245e --- /dev/null +++ b/examples/cloud-router-2-azure-connection/main.tf @@ -0,0 +1,36 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_azure_connection" { + source = "../../modules/cloud-router-connection" + + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_ap_type = var.aside_ap_type + aside_fcr_uuid = var.aside_fcr_uuid + + #Zside + zside_ap_type = var.zside_ap_type + zside_ap_authentication_key = var.zside_ap_authentication_key + zside_ap_profile_type = var.zside_ap_profile_type + zside_location = var.zside_location + zside_peering_type = var.zside_peering_type + zside_fabric_sp_name = var.zside_fabric_sp_name +} diff --git a/examples/cloud-router-2-azure-connection/outputs.tf b/examples/cloud-router-2-azure-connection/outputs.tf new file mode 100644 index 00000000..e6535aa5 --- /dev/null +++ b/examples/cloud-router-2-azure-connection/outputs.tf @@ -0,0 +1,3 @@ +output "module_output" { + value = module.cloud_router_azure_connection.primary_connection_id +} diff --git a/examples/cloud-router-2-azure-connection/terraform.tfvars.example b/examples/cloud-router-2-azure-connection/terraform.tfvars.example new file mode 100644 index 00000000..a637cc5d --- /dev/null +++ b/examples/cloud-router-2-azure-connection/terraform.tfvars.example @@ -0,0 +1,17 @@ +equinix_client_id = "" +equinix_client_secret = "" + +connection_name = "fcr_2_azure" +connection_type = "IP_VC" +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +bandwidth = 50 +aside_ap_type = "CLOUD_ROUTER" +aside_fcr_uuid = "" +zside_ap_type = "SP" +zside_ap_authentication_key = "" +zside_ap_profile_type = "L2_PROFILE" +zside_location = "SV" +zside_peering_type = "PRIVATE" +zside_fabric_sp_name = "Azure ExpressRoute" diff --git a/examples/cloud-router-2-azure-connection/variables.tf b/examples/cloud-router-2-azure-connection/variables.tf new file mode 100644 index 00000000..c7b51c90 --- /dev/null +++ b/examples/cloud-router-2-azure-connection/variables.tf @@ -0,0 +1,73 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string + +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} + +variable "zside_ap_authentication_key" { + description = "Authentication key for provider based connections" + type = string + default = "" +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_ap_profile_type" { + description = "Service profile type - L2_PROFILE, L3_PROFILE, ECIA_PROFILE, ECMC_PROFILE" + type = string + default = "L2_PROFILE" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} +variable "zside_peering_type" { + description = "Access point peering type - PRIVATE, MICROSOFT, PUBLIC, MANUAL" + default = "PRIVATE" +} + +variable "zside_fabric_sp_name" { + description = "Equinix Service Profile Name" + type = string + default = "" +} diff --git a/examples/cloud-router-2-azure-redundant-connection/README.md b/examples/cloud-router-2-azure-redundant-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-azure-redundant-connection/main.tf b/examples/cloud-router-2-azure-redundant-connection/main.tf new file mode 100644 index 00000000..f3b0d027 --- /dev/null +++ b/examples/cloud-router-2-azure-redundant-connection/main.tf @@ -0,0 +1,42 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_azure_redundant_connection" { + source = "../../modules/cloud-router-connection" + + #Primary Connection + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_ap_type = var.aside_ap_type + aside_fcr_uuid = var.aside_fcr_uuid + + #Zside + zside_ap_type = var.zside_ap_type + zside_ap_authentication_key = var.zside_ap_authentication_key + zside_ap_profile_type = var.zside_ap_profile_type + zside_location = var.zside_location + zside_fabric_sp_name = var.zside_fabric_sp_name + zside_peering_type = var.zside_peering_type + + #Secondary-Connection + secondary_connection_name = var.secondary_connection_name + secondary_bandwidth = var.secondary_bandwidth + aside_sec_fcr_uuid = var.aside_sec_fcr_uuid +} diff --git a/examples/cloud-router-2-azure-redundant-connection/outputs.tf b/examples/cloud-router-2-azure-redundant-connection/outputs.tf new file mode 100644 index 00000000..a9f37ac1 --- /dev/null +++ b/examples/cloud-router-2-azure-redundant-connection/outputs.tf @@ -0,0 +1,6 @@ +output "module_output" { + value = module.cloud_router_azure_redundant_connection.primary_connection_id +} +output "secondary_connection_result" { + value = var.secondary_connection_name != "" ? module.cloud_router_azure_redundant_connection.secondary_connection_id : null +} diff --git a/examples/cloud-router-2-azure-redundant-connection/terraform.tfvars.example b/examples/cloud-router-2-azure-redundant-connection/terraform.tfvars.example new file mode 100644 index 00000000..3357c3df --- /dev/null +++ b/examples/cloud-router-2-azure-redundant-connection/terraform.tfvars.example @@ -0,0 +1,21 @@ +equinix_client_id = "" +equinix_client_secret = "" + +connection_name = "fcr_2_azure_pri" +secondary_connection_name = "fcr_2_azure_sec" +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +connection_type = "IP_VC" +bandwidth = 50 +secondary_bandwidth = 50 +aside_ap_type = "CLOUD_ROUTER" +aside_fcr_uuid = "" +aside_sec_fcr_uuid = "" +zside_ap_type = "SP" +zside_ap_authentication_key = "" +zside_ap_profile_type = "L2_PROFILE" +zside_location = "SV" +zside_peering_type = "PRIVATE" +zside_seller_region = "us-west-1" +zside_fabric_sp_name = "Azure ExpressRoute" diff --git a/examples/cloud-router-2-azure-redundant-connection/variables.tf b/examples/cloud-router-2-azure-redundant-connection/variables.tf new file mode 100644 index 00000000..29e8ebfb --- /dev/null +++ b/examples/cloud-router-2-azure-redundant-connection/variables.tf @@ -0,0 +1,91 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string + +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} +variable "zside_ap_authentication_key" { + description = "Authentication key for provider based connections" + type = string + default = "" +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_ap_profile_type" { + description = "Service profile type - L2_PROFILE, L3_PROFILE, ECIA_PROFILE, ECMC_PROFILE" + type = string + default = "L2_PROFILE" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} +variable "zside_peering_type" { + description = "Access point peering type - PRIVATE, MICROSOFT, PUBLIC, MANUAL" + default = "PRIVATE" +} +variable "zside_fabric_sp_name" { + description = "Equinix Service Profile Name" + type = string + default = "" +} +variable "secondary_connection_name" { + description = "Secondary Connection name" + type = string + default = "" +} +variable "aside_sec_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier for Secondary Connection" + type = string + default = "" +} +variable "secondary_bandwidth" { + description = "Connection bandwidth in Mbps" + type = number + default = 50 +} +variable "secondary_redundancy" { + description = "Redundancy Priority for the Secondary connection" + type = string + default = "SECONDARY" +} diff --git a/examples/cloud-router-2-gcp-connection/README.md b/examples/cloud-router-2-gcp-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-gcp-connection/main.tf b/examples/cloud-router-2-gcp-connection/main.tf new file mode 100644 index 00000000..26bc7568 --- /dev/null +++ b/examples/cloud-router-2-gcp-connection/main.tf @@ -0,0 +1,36 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_gcp_connection" { + source = "../../modules/cloud-router-connection" + + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_ap_type = var.aside_ap_type + aside_fcr_uuid = var.aside_fcr_uuid + + #Zside + zside_ap_type = var.zside_ap_type + zside_ap_authentication_key = var.zside_ap_authentication_key + zside_ap_profile_type = var.zside_ap_profile_type + zside_location = var.zside_location + zside_seller_region = var.zside_seller_region + zside_fabric_sp_name = var.zside_fabric_sp_name +} diff --git a/examples/cloud-router-2-gcp-connection/outputs.tf b/examples/cloud-router-2-gcp-connection/outputs.tf new file mode 100644 index 00000000..080cdbb4 --- /dev/null +++ b/examples/cloud-router-2-gcp-connection/outputs.tf @@ -0,0 +1,3 @@ +output "module_output" { + value = module.cloud_router_gcp_connection.primary_connection_id +} diff --git a/examples/cloud-router-2-gcp-connection/terraform.tfvars.example b/examples/cloud-router-2-gcp-connection/terraform.tfvars.example new file mode 100644 index 00000000..1d5bb9c9 --- /dev/null +++ b/examples/cloud-router-2-gcp-connection/terraform.tfvars.example @@ -0,0 +1,17 @@ +equinix_client_id = "" +equinix_client_secret = "" + +connection_name = "fcr_2_gcp" +connection_type = "IP_VC" +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +bandwidth = 50 +aside_ap_type = "CLOUD_ROUTER" +aside_fcr_uuid = "" +zside_ap_type = "SP" +zside_ap_authentication_key = "" +zside_ap_profile_type = "L2_PROFILE" +zside_location = "SV" +zside_seller_region = "us-west-1" +zside_fabric_sp_name = "Google Cloud Partner Interconnect Zone 1" diff --git a/examples/cloud-router-2-gcp-connection/variables.tf b/examples/cloud-router-2-gcp-connection/variables.tf new file mode 100644 index 00000000..f62c7b71 --- /dev/null +++ b/examples/cloud-router-2-gcp-connection/variables.tf @@ -0,0 +1,73 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string + +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} + +variable "zside_ap_authentication_key" { + description = "Authentication key for provider based connections" + type = string + default = "" +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_ap_profile_type" { + description = "Service profile type - L2_PROFILE, L3_PROFILE, ECIA_PROFILE, ECMC_PROFILE" + type = string + default = "L2_PROFILE" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} +variable "zside_fabric_sp_name" { + description = "Equinix Service Profile Name" + type = string + default = "" +} +variable "zside_seller_region" { + description = "Access point seller region" + type = string + default = "" +} diff --git a/examples/cloud-router-2-oracle-connection/README.md b/examples/cloud-router-2-oracle-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-oracle-connection/main.tf b/examples/cloud-router-2-oracle-connection/main.tf new file mode 100644 index 00000000..f9f451b8 --- /dev/null +++ b/examples/cloud-router-2-oracle-connection/main.tf @@ -0,0 +1,37 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_oracle_connection" { + source = "../../modules/cloud-router-connection" + + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_ap_type = var.aside_ap_type + aside_fcr_uuid = var.aside_fcr_uuid + + #Zside + zside_ap_type = var.zside_ap_type + zside_ap_authentication_key = var.zside_ap_authentication_key + zside_ap_profile_type = var.zside_ap_profile_type + zside_location = var.zside_location + zside_peering_type = var.zside_peering_type + zside_seller_region = var.zside_seller_region + zside_fabric_sp_name = var.zside_fabric_sp_name +} diff --git a/examples/cloud-router-2-oracle-connection/outputs.tf b/examples/cloud-router-2-oracle-connection/outputs.tf new file mode 100644 index 00000000..2788ae94 --- /dev/null +++ b/examples/cloud-router-2-oracle-connection/outputs.tf @@ -0,0 +1,3 @@ +output "module_output" { + value = module.cloud_router_oracle_connection.primary_connection_id +} diff --git a/examples/cloud-router-2-oracle-connection/terraform.tfvars.example b/examples/cloud-router-2-oracle-connection/terraform.tfvars.example new file mode 100644 index 00000000..5e7114d5 --- /dev/null +++ b/examples/cloud-router-2-oracle-connection/terraform.tfvars.example @@ -0,0 +1,18 @@ +equinix_client_id = "" +equinix_client_secret = "" + +connection_name = "fcr_2_oracle" +connection_type = "IP_VC" +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +bandwidth = 1000 +aside_ap_type = "CLOUD_ROUTER" +aside_fcr_uuid = "" +zside_ap_type = "SP" +zside_ap_authentication_key = "" +zside_ap_profile_type = "L2_PROFILE" +zside_location = "SV" +zside_peering_type = "PRIVATE" +zside_seller_region = "us-ashburn-1" +zside_fabric_sp_name = "Oracle Cloud Infrastructure -OCI- FastConnect" diff --git a/examples/cloud-router-2-oracle-connection/variables.tf b/examples/cloud-router-2-oracle-connection/variables.tf new file mode 100644 index 00000000..16f6a502 --- /dev/null +++ b/examples/cloud-router-2-oracle-connection/variables.tf @@ -0,0 +1,75 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} +variable "zside_ap_authentication_key" { + description = "Authentication key for provider based connections" + type = string + default = "" +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_ap_profile_type" { + description = "Service profile type - L2_PROFILE, L3_PROFILE, ECIA_PROFILE, ECMC_PROFILE" + type = string + default = "L2_PROFILE" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} +variable "zside_peering_type" { + description = "Access point peering type - PRIVATE, MICROSOFT, PUBLIC, MANUAL" + default = "PRIVATE" +} +variable "zside_seller_region" { + description = "Access point seller region" + type = string + default = "" +} +variable "zside_fabric_sp_name" { + description = "Equinix Service Profile Name" + type = string + default = "" +} diff --git a/examples/cloud-router-2-port-connection/README.md b/examples/cloud-router-2-port-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-port-connection/main.tf b/examples/cloud-router-2-port-connection/main.tf new file mode 100644 index 00000000..a8d757fc --- /dev/null +++ b/examples/cloud-router-2-port-connection/main.tf @@ -0,0 +1,34 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_port_connection" { + source = "../../modules/cloud-router-connection" + + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_ap_type = var.aside_ap_type + aside_fcr_uuid = var.aside_fcr_uuid + + #Zside + zside_ap_type = var.zside_ap_type + zside_location = var.zside_location + zside_port_name = var.zside_port_name + zside_vlan_tag = var.zside_vlan_outer_tag +} diff --git a/examples/cloud-router-2-port-connection/outputs.tf b/examples/cloud-router-2-port-connection/outputs.tf new file mode 100644 index 00000000..96a4ef4b --- /dev/null +++ b/examples/cloud-router-2-port-connection/outputs.tf @@ -0,0 +1,3 @@ +output "module_output" { + value = module.cloud_router_port_connection.primary_connection_id +} diff --git a/examples/cloud-router-2-port-connection/terraform.tfvars.example b/examples/cloud-router-2-port-connection/terraform.tfvars.example new file mode 100644 index 00000000..1887feb7 --- /dev/null +++ b/examples/cloud-router-2-port-connection/terraform.tfvars.example @@ -0,0 +1,15 @@ +equinix_client_id = "" +equinix_client_secret = "" + +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +aside_fcr_uuid = "" +connection_name = "fcr_2_port" +connection_type = "IP_VC" +bandwidth = 50 +aside_ap_type = "CLOUD_ROUTER" +zside_ap_type = "COLO" +zside_vlan_outer_tag = "2711" +zside_location = "SV" +zside_port_name = "" diff --git a/examples/cloud-router-2-port-connection/variables.tf b/examples/cloud-router-2-port-connection/variables.tf new file mode 100644 index 00000000..77976cb6 --- /dev/null +++ b/examples/cloud-router-2-port-connection/variables.tf @@ -0,0 +1,61 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string + +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} +variable "zside_port_name" { + description = "Equinix Zside Port Name" + type = string +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_vlan_outer_tag" { + description = "Access point protocol Vlan tag number for DOT1Q or QINQ connections" + default = "" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} + diff --git a/examples/cloud-router-2-service-profile-connection/README.md b/examples/cloud-router-2-service-profile-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-service-profile-connection/main.tf b/examples/cloud-router-2-service-profile-connection/main.tf new file mode 100644 index 00000000..4e464739 --- /dev/null +++ b/examples/cloud-router-2-service-profile-connection/main.tf @@ -0,0 +1,34 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_sp_connection" { + source = "../../modules/cloud-router-connection" + + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_ap_type = var.aside_ap_type + aside_fcr_uuid = var.aside_fcr_uuid + + #Zside + zside_ap_type = var.zside_ap_type + zside_ap_profile_type = var.zside_ap_profile_type + zside_location = var.zside_location + zside_fabric_sp_name = var.zside_fabric_sp_name +} diff --git a/examples/cloud-router-2-service-profile-connection/outputs.tf b/examples/cloud-router-2-service-profile-connection/outputs.tf new file mode 100644 index 00000000..e27ea017 --- /dev/null +++ b/examples/cloud-router-2-service-profile-connection/outputs.tf @@ -0,0 +1,3 @@ +output "module_output" { + value = module.cloud_router_sp_connection.primary_connection_id +} diff --git a/examples/cloud-router-2-service-profile-connection/terraform.tfvars.example b/examples/cloud-router-2-service-profile-connection/terraform.tfvars.example new file mode 100644 index 00000000..292e9bcc --- /dev/null +++ b/examples/cloud-router-2-service-profile-connection/terraform.tfvars.example @@ -0,0 +1,15 @@ +equinix_client_id = "" +equinix_client_secret = "" + +connection_name = "fcr_2_sp" +connection_type = "IP_VC" +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +bandwidth = 50 +aside_ap_type = "CLOUD_ROUTER" +aside_fcr_uuid = "" +zside_ap_type = "SP" +zside_ap_profile_type = "L2_PROFILE" +zside_location = "SV" +zside_fabric_sp_name = "Ajith Ops User QnQ" diff --git a/examples/cloud-router-2-service-profile-connection/variables.tf b/examples/cloud-router-2-service-profile-connection/variables.tf new file mode 100644 index 00000000..5ca56215 --- /dev/null +++ b/examples/cloud-router-2-service-profile-connection/variables.tf @@ -0,0 +1,61 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_ap_profile_type" { + description = "Service profile type - L2_PROFILE, L3_PROFILE, ECIA_PROFILE, ECMC_PROFILE" + type = string + default = "L2_PROFILE" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} +variable "zside_fabric_sp_name" { + description = "Equinix Service Profile Name" + type = string + default = "" +} diff --git a/examples/cloud-router-2-wan-connection/README.md b/examples/cloud-router-2-wan-connection/README.md new file mode 100644 index 00000000..e69de29b diff --git a/examples/cloud-router-2-wan-connection/main.tf b/examples/cloud-router-2-wan-connection/main.tf new file mode 100644 index 00000000..5c76d736 --- /dev/null +++ b/examples/cloud-router-2-wan-connection/main.tf @@ -0,0 +1,32 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} + +provider "equinix" { + client_id = var.equinix_client_id + client_secret = var.equinix_client_secret +} + +module "cloud_router_wan_connection" { + source = "../../modules/cloud-router-connection" + + connection_name = var.connection_name + connection_type = var.connection_type + notifications_type = var.notifications_type + notifications_emails = var.notifications_emails + bandwidth = var.bandwidth + purchase_order_number = var.purchase_order_number + + #Aside + aside_ap_type = var.aside_ap_type + aside_fcr_uuid = var.aside_fcr_uuid + + #Zside + zside_ap_type = var.zside_ap_type + zside_network_uuid = var.zside_network_uuid +} diff --git a/examples/cloud-router-2-wan-connection/outputs.tf b/examples/cloud-router-2-wan-connection/outputs.tf new file mode 100644 index 00000000..1b64fc52 --- /dev/null +++ b/examples/cloud-router-2-wan-connection/outputs.tf @@ -0,0 +1,3 @@ +output "module_output" { + value = module.cloud_router_wan_connection.primary_connection_id +} diff --git a/examples/cloud-router-2-wan-connection/terraform.tfvars.example b/examples/cloud-router-2-wan-connection/terraform.tfvars.example new file mode 100644 index 00000000..b0111931 --- /dev/null +++ b/examples/cloud-router-2-wan-connection/terraform.tfvars.example @@ -0,0 +1,13 @@ +equinix_client_id = "" +equinix_client_secret = "" + +connection_name = "fcr_2_wan" +connection_type = "IPWAN_VC" +notifications_type = "ALL" +notifications_emails = ["example@equinix.com","test1@equinix.com"] +purchase_order_number = "1-323292" +bandwidth = 50 +aside_ap_type = "CLOUD_ROUTER" +aside_fcr_uuid = "" +zside_ap_type = "NETWORK" +zside_network_uuid = "" diff --git a/examples/cloud-router-2-wan-connection/variables.tf b/examples/cloud-router-2-wan-connection/variables.tf new file mode 100644 index 00000000..f141ca8d --- /dev/null +++ b/examples/cloud-router-2-wan-connection/variables.tf @@ -0,0 +1,50 @@ +variable "equinix_client_id" { + description = "Equinix client ID (consumer key), obtained after registering app in the developer platform" + type = string +} +variable "equinix_client_secret" { + description = "Equinix client secret ID (consumer secret), obtained after registering app in the developer platform" + type = string +} +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_network_uuid" { + description = "Network UUID" + default = "" +} diff --git a/modules/cloud-router-2-aws/README.md b/modules/cloud-router-2-aws/README.md deleted file mode 100644 index b77ea1bb..00000000 --- a/modules/cloud-router-2-aws/README.md +++ /dev/null @@ -1,45 +0,0 @@ -# ECX Fabric Layer2 Connection from fabric cloud router to AWS - -This example shows how create connection from Fabric Cloud Router to AWS, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `fcr_uuid` - UUID of ECX Fabric Cloud Router on a-side -- `zside_port_name` - Name of ECX Fabric z-side port , i.e. ops-user100-CX-SV5-NL-Qinq-BO-10G-SEC-JP-000 -- `connection_name` - the name of the connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `redundancy` - Port redundancy -- `aside_ap_type` - Fabric Cloud Router type -- `zside_ap_type` - Z side access point type -- `zside_ap_authentication_key` - AWS authorization key, account number like 357848912121 -- `zside_ap_profile_type` - Service profile type -- `fabric_sp_name` - Service profile name, fetched based on Service Profile get call using Service Profile search schema -- `zside_location` - Seller location -- `seller_region` - Seller region code - -## AWS login - -Log in to AWS portal use account that has permission to create necessary resources. - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2aws connection can be found at examples/fabric/v4/cloudRouterConnectivity/cloudRouter2aws/. - -- Change directory into - `examples/fabric/v4/cloudRouterConnectivity/cloudRouter2aws/` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to AWS connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|----------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2aws connection resource | -| READ | `terraform show` | Reads/Shows the current state of the fcr2aws connection resource | -| UPDATE | `terraform apply -refresh` | Updates the fcr2aws with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2aws connection resource | \ No newline at end of file diff --git a/modules/cloud-router-2-aws/main.tf b/modules/cloud-router-2-aws/main.tf deleted file mode 100644 index a12dcfd2..00000000 --- a/modules/cloud-router-2-aws/main.tf +++ /dev/null @@ -1,55 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} -data "equinix_fabric_service_profiles" "aws" { - filter { - property = "/name" - operator = "=" - values = [var.fabric_sp_name] - } -} - - -resource "equinix_fabric_connection" "fcr2aws"{ - name = var.connection_name - type = var.connection_type - notifications{ - type=var.notifications_type - emails=var.notifications_emails - } - additional_info= [{"key"= "accessKey", "value"= var.aws_access_key }, {"key"= "secretKey", "value"= var.aws_secret_key }] - bandwidth = var.bandwidth - redundancy {priority= var.redundancy} - - order { - purchase_order_number= var.purchase_order_number - } - a_side { - access_point { - type= var.aside_ap_type - router { - uuid= var.fcr_uuid - } - } - } - z_side { - access_point { - type= var.zside_ap_type - authentication_key= var.zside_ap_authentication_key - seller_region = var.seller_region - profile { - type= var.zside_ap_profile_type - uuid= data.equinix_fabric_service_profiles.aws.data.0.uuid - } - location { - metro_code= var.zside_location - } - } - } -} - -output "connection_result" { - value = equinix_fabric_connection.fcr2aws.id -} - diff --git a/modules/cloud-router-2-aws/terraform.tf b/modules/cloud-router-2-aws/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-aws/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-aws/terraform.tfvars.example b/modules/cloud-router-2-aws/terraform.tfvars.example deleted file mode 100644 index c79d7c1d..00000000 --- a/modules/cloud-router-2-aws/terraform.tfvars.example +++ /dev/null @@ -1,22 +0,0 @@ -equinix_client_id = "" -equinix_client_secret = "" - -notifications_type = "ALL" -notifications_emails = ["example@equinix.com","test1@equinix.com"] -purchase_order_number = "1-323292" -fcr_uuid = "3d8ec863-06b4-4887-9feb-ccacb82923d5" -connection_name = "terra_fcr2aws-2" -connection_type = "IP_VC" -bandwidth = 50 -redundancy = "SECONDARY" -aside_ap_type = "CLOUD_ROUTER" - -zside_ap_type = "SP" -zside_ap_authentication_key = "" -zside_ap_profile_type = "L2_PROFILE" -zside_location = "SV" -seller_region = "us-west-1" -fabric_sp_name = "AWS Direct Connect" - -aws_access_key = "AWS Client Access Key" -aws_secret_key = "AWS Client Secret Key" diff --git a/modules/cloud-router-2-aws/variables.tf b/modules/cloud-router-2-aws/variables.tf deleted file mode 100644 index 4ba75cb1..00000000 --- a/modules/cloud-router-2-aws/variables.tf +++ /dev/null @@ -1,24 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} - -variable "fcr_uuid" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "purchase_order_number" {} - -variable "connection_name" {} -variable "connection_type" {} -variable "bandwidth" {} -variable "redundancy" {} - -variable "aside_ap_type" {} -variable "zside_ap_type" {} -variable "zside_ap_authentication_key" {} - -variable "zside_ap_profile_type" {} -variable "fabric_sp_name" {} -variable "zside_location" {} -variable "seller_region" {} - -variable "aws_access_key" {} -variable "aws_secret_key" {} diff --git a/modules/cloud-router-2-azure/single-connection/README.md b/modules/cloud-router-2-azure/single-connection/README.md deleted file mode 100644 index 953d0286..00000000 --- a/modules/cloud-router-2-azure/single-connection/README.md +++ /dev/null @@ -1,44 +0,0 @@ -# ECX Fabric Layer2 Single Connection from fabric cloud router to Azure - -This example shows how create single connection from Fabric Cloud Router to Azure, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `fcr_uuid` - UUID of ECX Fabric Cloud Router on a-sideshow -- `connection_name` - the name of the connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `redundancy` - Port redundancy -- `aside_ap_type` - Fabric Cloud Router type -- `zside_ap_type` - Z side access point type -- `zside_ap_authentication_key` - Azure authorization key, service key generated from Azure Portal -- `zside_ap_profile_type` - Service profile type -- `fabric_sp_name` - Service profile name, fetched based on Service Profile get call using Service Profile search schema -- `zside_location` - Seller location -- `seller_region` - Seller region code - -## Azure login - -Log in to Azure portal use account that has permission to create necessary resources. - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2azure connection can be found at examples/fabric/v4/cloudRouterConnectivity/cloudRouter2azure/single-connection/. - -- Change directory into - `CD examples/fabric/v4/cloudRouterConnectivity/cloudRouter2azure/single-connection/` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to Azure single connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|------------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2azure connection resource | -| READ | `terraform show` | Reads/Shows the current state of the fcr2azure connection resource | -| UPDATE | `terraform apply -refresh` | Updates the fcr2azure with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2azure connection resource | diff --git a/modules/cloud-router-2-azure/single-connection/main.tf b/modules/cloud-router-2-azure/single-connection/main.tf deleted file mode 100644 index c7b1af85..00000000 --- a/modules/cloud-router-2-azure/single-connection/main.tf +++ /dev/null @@ -1,56 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} - -data "equinix_fabric_service_profiles" "azure"{ - filter{ - property = "/name" - operator = "=" - values = [var.fabric_sp_name] - } -} - -resource "equinix_fabric_connection" "fcr2azure"{ - name = var.connection_name - type = var.connection_type - - notifications { - type = var.notifications_type - emails = var.notifications_emails - } - - bandwidth = var.bandwidth - redundancy {priority= var.redundancy} - order { - purchase_order_number = var.purchase_order_number - } - a_side { - access_point { - type = var.aside_ap_type - router { - uuid = var.fcr_uuid - } - } - } - - z_side { - access_point { - type = var.zside_ap_type - authentication_key = var.zside_ap_authentication_key - peering_type = var.peering_type - profile { - type = var.zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.azure.id - } - location { - metro_code = var.zside_location - } - } - } -} - -output "connection_result" { - value = equinix_fabric_connection.fcr2azure.id -} - diff --git a/modules/cloud-router-2-azure/single-connection/terraform.tf b/modules/cloud-router-2-azure/single-connection/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-azure/single-connection/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-azure/single-connection/terraform.tfvars.example b/modules/cloud-router-2-azure/single-connection/terraform.tfvars.example deleted file mode 100644 index 05d99e80..00000000 --- a/modules/cloud-router-2-azure/single-connection/terraform.tfvars.example +++ /dev/null @@ -1,18 +0,0 @@ -equinix_client_id = "Equinix_Client_Id" -equinix_client_secret = "Equinix_Client_Secret" -connection_name = "fcr_2_azure" -connection_type = "IP_VC" -notifications_type = "ALL" -notifications_emails = ["example@equinix.com"] -bandwidth = 50 -redundancy = "PRIMARY" -redundancy_group_uuid = "" #OPTIONAL -purchase_order_number = "1-323292" -peering_type = "PRIVATE" -aside_ap_type = "CLOUD_ROUTER" -fcr_uuid = "Cloud Router UUID" -zside_ap_type = "SP" -zside_ap_authentication_key = "Azure Service Key" -zside_ap_profile_type = "L2_PROFILE" -zside_location = "SV" -fabric_sp_name = "Azure ExpressRoute" diff --git a/modules/cloud-router-2-azure/single-connection/variables.tf b/modules/cloud-router-2-azure/single-connection/variables.tf deleted file mode 100644 index e274270c..00000000 --- a/modules/cloud-router-2-azure/single-connection/variables.tf +++ /dev/null @@ -1,18 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} -variable "connection_name" {} -variable "connection_type" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "bandwidth" {} -variable "redundancy" {} -variable "redundancy_group_uuid" {} -variable "purchase_order_number" {} -variable "peering_type" {} -variable "aside_ap_type" {} -variable "fcr_uuid" {} -variable "zside_ap_type" {} -variable "zside_ap_authentication_key" {} -variable "zside_ap_profile_type" {} -variable "zside_location" {} -variable "fabric_sp_name" {} diff --git a/modules/cloud-router-2-azure/two-connections/README.md b/modules/cloud-router-2-azure/two-connections/README.md deleted file mode 100644 index bed6254a..00000000 --- a/modules/cloud-router-2-azure/two-connections/README.md +++ /dev/null @@ -1,47 +0,0 @@ -# ECX Fabric Layer2 Two Redundant Connections from fabric cloud router to Azure - -This example shows how create two redundant connections from Fabric Cloud Router to Azure, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `pri_connection_name` - the name of the primary connection -- `sec_connection_name` - the name of the secondary connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `aside_ap_type` - Fabric Cloud Router type -- `peering_type` - Peering type for the ECX Fabric Cloud Router on the a-side; typically PRIVATE -**Note: You can use one Cloud Router for both connections if you would like** -- `cloud_router_primary_uuid` - UUID of ECX Fabric Cloud Router on a-side -- `cloud_router_secondary_uuid` - UUID of ECX Fabric Cloud Router on a-side for secondary connection -- `zside_ap_type` - Z side access point type -- `zside_ap_authentication_key` - Azure authorization key, service key generated from Azure Portal -- `zside_ap_profile_type` - Service profile type -- `zside_ap_profile_uuid` - Service profile UUID -- `zside_location` - Seller location -- `fabric_sp_name` - Service profile name, fetched based on Service Profile get call using Service Profile search schema - -## Azure login - -Log in to Azure portal use account that has permission to create necessary resources. - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2azure connection can be found at examples/fabric/v4/cloudRouterConnectivity/cloudRouter2azure/two-connections/. - -- Change directory into - `CD examples/fabric/v4/cloudRouterConnectivity/cloudRouter2azure/two-connections/` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to Azure Two connections : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|------------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2azure redundant connection resources | -| READ | `terraform show` | Reads/Shows the current state of the fcr2azure connection resources | -| UPDATE | `terraform apply -refresh` | Updates the fcr2azure with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2azure connection resources | \ No newline at end of file diff --git a/modules/cloud-router-2-azure/two-connections/main.tf b/modules/cloud-router-2-azure/two-connections/main.tf deleted file mode 100644 index b776ec55..00000000 --- a/modules/cloud-router-2-azure/two-connections/main.tf +++ /dev/null @@ -1,109 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} - -data "equinix_fabric_service_profiles" "azure" { - filter { - property = "/name" - operator = "=" - values = [var.fabric_sp_name] - } -} - -resource "equinix_fabric_connection" "fcr2azure" { - name = var.pri_connection_name - type = var.connection_type - - notifications { - type = var.notifications_type - emails = var.notifications_emails - } - - bandwidth = var.bandwidth - redundancy { - priority = "PRIMARY" - } - order { - purchase_order_number = var.pri_purchase_order_number - } - a_side { - access_point { - type = var.aside_ap_type - router { - uuid = var.cloud_router_primary_uuid - } - } - } - - z_side { - access_point { - type = var.zside_ap_type - authentication_key = var.zside_ap_authentication_key - profile { - type = var.zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.azure.id - } - location { - metro_code = var.zside_location - } - peering_type = var.peering_type - } - } -} - -resource "equinix_fabric_connection" "fcr2azure2" { - name = var.sec_connection_name - - type = var.connection_type - - notifications { - type = var.notifications_type - emails = var.notifications_emails - } - - bandwidth = var.bandwidth - /*`redundancy` - Cloud router redundancy **Note: in order to use resource dependency with redundancy because - it is a set type with max items of 1; put it into the one() terraform function before attempting to address - its children. - I.e. one(equinix_fabric_connection.connection_name.redundancy).group** - */ - redundancy { - priority = "SECONDARY" - group = one(equinix_fabric_connection.fcr2azure.redundancy).group - } - order { - purchase_order_number = var.sec_purchase_order_number - } - a_side { - access_point { - type = var.aside_ap_type - router { - uuid = var.cloud_router_secondary_uuid - } - } - } - - z_side { - access_point { - type = var.zside_ap_type - authentication_key = var.zside_ap_authentication_key - profile { - type = var.zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.azure.id - } - location { - metro_code = var.zside_location - } - peering_type = var.peering_type - } - } -} - -output "primary_connection_result" { - value = equinix_fabric_connection.fcr2azure.id -} - -output "secondary_connection_result" { - value = equinix_fabric_connection.fcr2azure2.id -} diff --git a/modules/cloud-router-2-azure/two-connections/terraform.tf b/modules/cloud-router-2-azure/two-connections/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-azure/two-connections/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-azure/two-connections/terraform.tfvars.example b/modules/cloud-router-2-azure/two-connections/terraform.tfvars.example deleted file mode 100644 index b3d9fccd..00000000 --- a/modules/cloud-router-2-azure/two-connections/terraform.tfvars.example +++ /dev/null @@ -1,19 +0,0 @@ -equinix_client_id = "Equinix_Client_Id" -equinix_client_secret = "Equinix_Client_Secret" -pri_connection_name = "fcr_2_azure_pri" -sec_connection_name = "fcr_2_azure_sec" -connection_type = "IP_VC" -notifications_type = "ALL" -notifications_emails = ["example@equinix.com"] -bandwidth = 50 -pri_purchase_order_number = "1-323202" -sec_purchase_order_number = "1-323292" -peering_type = "PRIVATE" -aside_ap_type = "CLOUD_ROUTER" -cloud_router_primary_uuid = "19514e72-f1c0-497c-a550-664aa75cb28c" -cloud_router_secondary_uuid = "56cfbf37-2ffd-4dac-b797-782bb5f459fc" -zside_ap_type = "SP" -zside_ap_authentication_key = "Azure Service Key" -zside_ap_profile_type = "L2_PROFILE" -zside_location = "SV" -fabric_sp_name = "Azure ExpressRoute" diff --git a/modules/cloud-router-2-azure/two-connections/variables.tf b/modules/cloud-router-2-azure/two-connections/variables.tf deleted file mode 100644 index ee4161fc..00000000 --- a/modules/cloud-router-2-azure/two-connections/variables.tf +++ /dev/null @@ -1,19 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} -variable "pri_connection_name" {} -variable "sec_connection_name" {} -variable "connection_type" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "bandwidth" {} -variable "pri_purchase_order_number" {} -variable "sec_purchase_order_number" {} -variable "peering_type" {} -variable "aside_ap_type" {} -variable "cloud_router_primary_uuid" {} -variable "cloud_router_secondary_uuid" {} -variable "zside_ap_type" {} -variable "zside_ap_authentication_key" {} -variable "zside_ap_profile_type" {} -variable "zside_location" {} -variable "fabric_sp_name" {} diff --git a/modules/cloud-router-2-gcp/README.md b/modules/cloud-router-2-gcp/README.md deleted file mode 100644 index cbe182fd..00000000 --- a/modules/cloud-router-2-gcp/README.md +++ /dev/null @@ -1,40 +0,0 @@ -# ECX Fabric Layer2 Connection from fabric cloud router to google - -This example shows how create connection from Fabric Cloud Router to google, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `fcr_uuid` - UUID of ECX Fabric Cloud Router on a-side -- `zside_port_name` - Name of ECX Fabric z-side port , i.e. ops-user100-CX-SV5-NL-Qinq-BO-10G-SEC-JP-000 -- `connection_name` - the name of the connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `redundancy` - Port redundancy -- `aside_ap_type` - Fabric Cloud Router type -- `zside_ap_type` - Z side access point type -- `zside_ap_authentication_key` - Google authorization key following a pattern, like **9da09fe8-a33b-4457-ab7d-d91f83152276/us-west1/1** -- `zside_ap_profile_type` - Service profile type -- `zside_location` - Seller location -- `seller_region` - Seller region code - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2gcp connection can be found at examples/fabric/v4/cloudRouterConnectivity/cloudRouter2gcp/. - -- Change directory into - `CD examples/fabric/v4/cloudRouterConnectivity/cloudRouter2gcp/` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to GCP connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|----------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2gcp connection resource | -| READ | `terraform show` | Reads/Shows the current state of the fcr2gcp connection resource | -| UPDATE | `terraform apply -refresh` | Updates the fcr2gcp with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2gcp connection resource | \ No newline at end of file diff --git a/modules/cloud-router-2-gcp/main.tf b/modules/cloud-router-2-gcp/main.tf deleted file mode 100644 index ff53c043..00000000 --- a/modules/cloud-router-2-gcp/main.tf +++ /dev/null @@ -1,56 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} - -data "equinix_fabric_service_profiles" "gcp" { - filter { - property = "/name" - operator = "=" - values = [var.fabric_sp_name] - } -} - -resource "equinix_fabric_connection" "fcr2gcp"{ - name = var.connection_name - type = var.connection_type - notifications{ - type=var.notifications_type - emails=var.notifications_emails - } - bandwidth = var.bandwidth - redundancy {priority= var.redundancy} - - order { - purchase_order_number= var.purchase_order_number - } - a_side { - access_point { - type= var.aside_ap_type - router { - uuid= var.fcr_uuid - } - } - } - - z_side { - access_point { - type = var.zside_ap_type - authentication_key = var.zside_ap_authentication_key - seller_region = var.zside_seller_region - profile { - type = var.zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.gcp.data.0.uuid - } - location { - metro_code = var.zside_location - } - } - } - -} - -output "connection_result" { - value = equinix_fabric_connection.fcr2gcp.id -} - diff --git a/modules/cloud-router-2-gcp/terraform.tf b/modules/cloud-router-2-gcp/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-gcp/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-gcp/terraform.tfvars.example b/modules/cloud-router-2-gcp/terraform.tfvars.example deleted file mode 100644 index 00e19b13..00000000 --- a/modules/cloud-router-2-gcp/terraform.tfvars.example +++ /dev/null @@ -1,19 +0,0 @@ -equinix_client_id = "" -equinix_client_secret = "" - -notifications_type = "ALL" -notifications_emails = ["example@equinix.com","test1@equinix.com"] -purchase_order_number = "1-323292" -fcr_uuid = "3d8ec863-06b4-4887-9feb-ccacb82923d5" -connection_name = "conn-terra_gcp2" -connection_type = "IP_VC" -bandwidth = 50 -redundancy = "SECONDARY" -aside_ap_type = "CLOUD_ROUTER" - -zside_ap_type = "SP" -zside_ap_authentication_key = "/us-west1/2" -zside_ap_profile_type = "L2_PROFILE" -zside_location = "SV" -zside_seller_region="us-west1" -fabric_sp_name = "Google Cloud Partner Interconnect Zone 1" diff --git a/modules/cloud-router-2-gcp/variables.tf b/modules/cloud-router-2-gcp/variables.tf deleted file mode 100644 index aa8e8d76..00000000 --- a/modules/cloud-router-2-gcp/variables.tf +++ /dev/null @@ -1,21 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} - -variable "fcr_uuid" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "purchase_order_number" {} - -variable "connection_name" {} -variable "connection_type" {} -variable "bandwidth" {} -variable "redundancy" {} - -variable "aside_ap_type" {} -variable "zside_ap_type" {} -variable "zside_ap_authentication_key" {} - -variable "zside_ap_profile_type" {} -variable "fabric_sp_name" {} -variable "zside_location" {} -variable "zside_seller_region" {} diff --git a/modules/cloud-router-2-ipwan/README.md b/modules/cloud-router-2-ipwan/README.md deleted file mode 100644 index 08be5457..00000000 --- a/modules/cloud-router-2-ipwan/README.md +++ /dev/null @@ -1,39 +0,0 @@ -# ECX Fabric Layer2 Connection from fabric cloud router to ipwan - -This example shows how create connection from Fabric Cloud Router to ipwan, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -* `equinix_client_id` - Equinix client ID (consumer key), obtained after - registering app in the developer platform -* `equinix_client_secret` - Equinix client secret ID (consumer secret), - obtained same way as above - -`fcr_uuid` - UUID of ECX Fabric Cloud Router on a-side -`network_uuid` - UUID of ipwan network on z-side -`connection_name` - the name of the connection -`connection_type` - connection type, please refer schema -`notifications_type` - notification type -`notifications_emails` - List of emails -`purchase_order_number` - Purchase order number -`bandwidth` - bandwidth in MBs -`aside_ap_type` - Fabric Cloud Router type -`zside_ap_type` - Z side access point type, ipwan - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2wan connection can be found at examples/fcr2port/. - -- Change directory into - `CD examples/fabric/v4/cloudRouterConnectivity/cloudRouter2wan/` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to wan connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|----------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2wan connection resource | -| READ | `terraform show` | Reads/Shows the current state of the fcr2wan connection resource | -| UPDATE | `terraform apply -refresh` | Updates the fcr2wan with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2wan connection resource | \ No newline at end of file diff --git a/modules/cloud-router-2-ipwan/main.tf b/modules/cloud-router-2-ipwan/main.tf deleted file mode 100644 index 27899ce0..00000000 --- a/modules/cloud-router-2-ipwan/main.tf +++ /dev/null @@ -1,40 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} - - -resource "equinix_fabric_connection" "fcr2ipwan" { - name = var.connection_name - type = var.connection_type - notifications { - type = var.notifications_type - emails = var.notifications_emails - } - bandwidth = var.bandwidth - - order { - purchase_order_number = var.purchase_order_number - } - a_side { - access_point { - type = var.aside_ap_type - router { - uuid = var.fcr_uuid - } - } - } - z_side { - access_point { - type = var.zside_ap_type - network { - uuid = var.network_uuid - } - } - } -} - -output "connection_result" { - value = equinix_fabric_connection.fcr2ipwan.id -} - diff --git a/modules/cloud-router-2-ipwan/terraform.tf b/modules/cloud-router-2-ipwan/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-ipwan/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-ipwan/terraform.tfvars.example b/modules/cloud-router-2-ipwan/terraform.tfvars.example deleted file mode 100644 index 8754eda7..00000000 --- a/modules/cloud-router-2-ipwan/terraform.tfvars.example +++ /dev/null @@ -1,12 +0,0 @@ -equinix_client_id = "" -equinix_client_secret = "" -notifications_type = "ALL" -notifications_emails = ["example@equinix.com", "test1@equinix.com"] -purchase_order_number = "1-323292" -fcr_uuid = "" -connection_name = "terraform_fcr2wan" -connection_type = "IPWAN_VC" -bandwidth = 50 -aside_ap_type = "CLOUD_ROUTER" -zside_ap_type = "NETWORK" -network_uuid = "" diff --git a/modules/cloud-router-2-ipwan/variables.tf b/modules/cloud-router-2-ipwan/variables.tf deleted file mode 100644 index ec1714f5..00000000 --- a/modules/cloud-router-2-ipwan/variables.tf +++ /dev/null @@ -1,18 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} - -variable "fcr_uuid" {} -variable "network_uuid" {} - -variable "notifications_type" {} -variable "notifications_emails" {} -variable "purchase_order_number" {} - -variable "connection_name" {} -variable "connection_type" {} -variable "bandwidth" {} - -variable "aside_ap_type" {} -variable "zside_ap_type" {} - - diff --git a/modules/cloud-router-2-oracle/README.md b/modules/cloud-router-2-oracle/README.md deleted file mode 100644 index 694260c0..00000000 --- a/modules/cloud-router-2-oracle/README.md +++ /dev/null @@ -1,44 +0,0 @@ -# ECX Fabric Layer2 Single Connection from fabric cloud router to Oracle - -This example shows how create single connection from Fabric Cloud Router to Oracle, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `fcr_uuid` - UUID of ECX Fabric Cloud Router on a-sideshow -- `connection_name` - the name of the connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `redundancy` - Port redundancy -- `aside_ap_type` - Fabric Cloud Router type -- `zside_ap_type` - Z side access point type -- `zside_ap_authentication_key` - Oracle authorization key following a pattern, like **ocid1.virtualcircuit.oc1.phx.aaaaaaaa62hgxtczqwpaour5gnaq4qn2wupjwpqtsknr2mvxblrcdtusda1a** -- `zside_ap_profile_type` - Service profile type -- `fabric_sp_name` - Service profile name, fetched based on Service Profile get call using Service Profile search schema -- `zside_location` - Seller location -- `seller_region` - Seller region code - -## Oracle login - -Log in to Oracle Cloud portal use account that has permission to create necessary resources. - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2oracle connection can be found at examples/fabric/v4/cloudRouterConnectivity/cloudRouter2oracle/. - -- Change directory into - ` CD examples/fabric/v4/cloudRouterConnectivity/cloudRouter2oracle/` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to Oracle connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|-------------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2oracle connection resource | -| READ | `terraform show` | Reads/Shows the current state of the fcr2oracle connection resource | -| UPDATE | `terraform apply -refresh` | Updates the fcr2oracle with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2oracle connection resource | diff --git a/modules/cloud-router-2-oracle/main.tf b/modules/cloud-router-2-oracle/main.tf deleted file mode 100644 index 3da91578..00000000 --- a/modules/cloud-router-2-oracle/main.tf +++ /dev/null @@ -1,54 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} - -data "equinix_fabric_service_profiles" "oracle" { - filter { - property = "/name" - operator = "=" - values = [var.fabric_sp_name] - } -} - - -resource "equinix_fabric_connection" "fcr2oracle" { - name = var.connection_name - type = var.connection_type - notifications{ - type=var.notifications_type - emails=var.notifications_emails - } - bandwidth = var.bandwidth - order { - purchase_order_number= var.purchase_order_number - } - a_side { - access_point { - type = var.aside_ap_type - router { - uuid = var.fcr_uuid - } - } - } - z_side { - access_point { - type = var.zside_ap_type - authentication_key = var.zside_ap_authentication_key - seller_region = var.seller_region - peering_type = var.peering_type - profile { - type = var.zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.oracle.id - } - location { - metro_code = var.zside_location - } - } - } -} - -output "connection_result" { - value = equinix_fabric_connection.fcr2oracle.id -} - diff --git a/modules/cloud-router-2-oracle/terraform.tf b/modules/cloud-router-2-oracle/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-oracle/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-oracle/terraform.tfvars.example b/modules/cloud-router-2-oracle/terraform.tfvars.example deleted file mode 100644 index 201148cf..00000000 --- a/modules/cloud-router-2-oracle/terraform.tfvars.example +++ /dev/null @@ -1,17 +0,0 @@ -equinix_client_id = "Equinix_Client_Id" -equinix_client_secret = "Equinix_Client_Secret" -connection_name = "fcr_oci_pri" -connection_type = "IP_VC" -notifications_type = "ALL" -notifications_emails = ["example@equinix.com"] -bandwidth = 50 -purchase_order_number = "1-323292" -aside_ap_type = "CLOUD_ROUTER" -fcr_uuid = "Fabric CLoud Router UUID" -peering_type = "PRIVATE" -zside_ap_type = "SP" -zside_ap_authentication_key = "Oracle Authentication Key" -zside_ap_profile_type = "L2_PROFILE" -zside_location = "DC" -seller_region = "us-ashburn-1" -fabric_sp_name = "Oracle Cloud Infrastructure -OCI- FastConnect" diff --git a/modules/cloud-router-2-oracle/variables.tf b/modules/cloud-router-2-oracle/variables.tf deleted file mode 100644 index 13259f53..00000000 --- a/modules/cloud-router-2-oracle/variables.tf +++ /dev/null @@ -1,17 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} -variable "connection_name" {} -variable "connection_type" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "bandwidth" {} -variable "purchase_order_number" {} -variable "aside_ap_type" {} -variable "fcr_uuid" {} -variable "peering_type" {} -variable "zside_ap_type" {} -variable "zside_ap_authentication_key" {} -variable "zside_ap_profile_type" {} -variable "zside_location" {} -variable "seller_region" {} -variable "fabric_sp_name" {} diff --git a/modules/cloud-router-2-port/README.md b/modules/cloud-router-2-port/README.md deleted file mode 100644 index 61b69910..00000000 --- a/modules/cloud-router-2-port/README.md +++ /dev/null @@ -1,38 +0,0 @@ -# ECX Fabric Layer2 Connection from fabric cloud router to port - -This example shows how create connection from Fabric Cloud Router to port, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `fcr_uuid` - UUID of ECX Fabric Cloud Router on a-side -- `zside_port_name` - Name of ECX Fabric z-side port , i.e. ops-user100-CX-SV5-NL-Qinq-BO-10G-SEC-JP-000 -- `connection_name` - the name of the connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `redundancy` - Port redundancy -- `aside_ap_type` - Fabric Cloud Router type -- `zside_ap_type` - Z side access point type -- `zside_link_protocol_tag` - z-side vlan tag number -- `zside_location` - Seller location - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2port connection can be found at examples/fcr2port/. - -- Change directory into - `CD examples/fcr2port/` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to port connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|-----------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2port connection resource | -| READ | `terraform show` | Reads/Shows the current state of the fcr2port connection resource | -| UPDATE | `terraform apply -refresh` | Updates the fcr2port with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2port connection resource | \ No newline at end of file diff --git a/modules/cloud-router-2-port/main.tf b/modules/cloud-router-2-port/main.tf deleted file mode 100644 index ddddfcf1..00000000 --- a/modules/cloud-router-2-port/main.tf +++ /dev/null @@ -1,48 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} -data "equinix_fabric_ports" "zside" { - filters { - name = var.zside_port_name - } -} -resource "equinix_fabric_connection" "fcr2port"{ - name = var.connection_name - type = var.connection_type - notifications{ - type=var.notifications_type - emails=var.notifications_emails - } - bandwidth = var.bandwidth - order { - purchase_order_number= var.purchase_order_number - } - a_side { - access_point { - type= var.aside_ap_type - router { - uuid= var.fcr_uuid - } - } - } - z_side { - access_point { - type= var.zside_ap_type - port { - uuid= data.equinix_fabric_ports.zside.data.0.uuid - } - link_protocol { - type= var.zside_link_protocol_type - vlan_tag= var.zside_link_protocol_tag - } - location { - metro_code= var.zside_location - } - } - } -} - -output "connection_result" { - value = equinix_fabric_connection.fcr2port.id -} diff --git a/modules/cloud-router-2-port/terraform.tf b/modules/cloud-router-2-port/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-port/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-port/terraform.tfvars.example b/modules/cloud-router-2-port/terraform.tfvars.example deleted file mode 100644 index 6e82517d..00000000 --- a/modules/cloud-router-2-port/terraform.tfvars.example +++ /dev/null @@ -1,17 +0,0 @@ -equinix_client_id = "" -equinix_client_secret = "" - -notifications_type = "ALL" -notifications_emails = ["example@equinix.com","test1@equinix.com"] -purchase_order_number = "1-323292" -fcr_uuid = "3d8ec863-06b4-4887-9feb-ccacb82923d5" -connection_name = "conn-terra_demo" -connection_type = "IP_VC" -bandwidth = 50 -redundancy = "PRIMARY" -aside_ap_type = "CLOUD_ROUTER" -zside_ap_type = "COLO" -zside_link_protocol_type = "DOT1Q" -zside_link_protocol_tag = "2711" -zside_location = "SV" -zside_port_name = "svc3" \ No newline at end of file diff --git a/modules/cloud-router-2-port/variables.tf b/modules/cloud-router-2-port/variables.tf deleted file mode 100644 index 13ae1d78..00000000 --- a/modules/cloud-router-2-port/variables.tf +++ /dev/null @@ -1,17 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} - -variable "notifications_type" {} -variable "notifications_emails" {} -variable "purchase_order_number" {} -variable "connection_name" {} -variable "connection_type" {} -variable "bandwidth" {} -variable "redundancy" {} -variable "aside_ap_type" {} -variable "zside_ap_type" {} -variable "zside_link_protocol_type" {} -variable "zside_link_protocol_tag" {} -variable "zside_location" {} -variable "zside_port_name" {} -variable "fcr_uuid" {} diff --git a/modules/cloud-router-2-service-profile/README.md b/modules/cloud-router-2-service-profile/README.md deleted file mode 100644 index ad9b40aa..00000000 --- a/modules/cloud-router-2-service-profile/README.md +++ /dev/null @@ -1,38 +0,0 @@ -# ECX Fabric Layer2 Single Connection from fabric cloud router to Service Profile - -This example shows how create single connection from Fabric Cloud Router to Seller Service Profile, on ECX Fabric ports. - -## Adjust variables -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `fcr_uuid` - UUID of ECX Fabric Cloud Router on a-sideshow -- `connection_name` - the name of the connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `redundancy` - Port redundancy -- `aside_ap_type` - Fabric Cloud Router type -- `zside_ap_type` - Z side access point type -- `zside_ap_profile_type` - Service profile type -- `fabric_sp_name` - Service profile name, fetched based on Service Profile get call using Service Profile search schema -- `zside_location` - Seller location - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations on a fcr2serviceprofile connection can be found at examples/fabric/v4/cloudRouterConnectivity/cloudRouter2serviceprofile. - -- Change directory into - `CD cloudRouter2serviceprofile` -- Initialize Terraform plugins - `terraform init` - -## Fabric Cloud Router to ServiceProfile connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|---------------------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a fcr2serviceprofile connection resource | -| READ | `terraform show` | Reads/Shows the current state of the fcr2serviceprofile connection resource | -| UPDATE | `terraform apply -refresh` | Updates the fcr2serviceprofile with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created fcr2serviceprofile connection resource | \ No newline at end of file diff --git a/modules/cloud-router-2-service-profile/main.tf b/modules/cloud-router-2-service-profile/main.tf deleted file mode 100644 index d9b98c46..00000000 --- a/modules/cloud-router-2-service-profile/main.tf +++ /dev/null @@ -1,50 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} - -data "equinix_fabric_service_profiles" "sp" { - filter { - property = "/name" - operator = "=" - values = [var.fabric_sp_name] - } -} - -resource "equinix_fabric_connection" "fcr2profile" { - name = var.connection_name - type = var.connection_type - notifications{ - type = var.notifications_type - emails = var.notifications_emails - } - bandwidth = var.bandwidth - redundancy {priority = var.redundancy} - order { - purchase_order_number = var.purchase_order_number - } - a_side { - access_point { - type = var.aside_ap_type - router { - uuid = var.fcr_uuid - } - } - } - z_side { - access_point { - type = var.zside_ap_type - profile { - type = var.zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.sp.id - } - location { - metro_code = var.zside_location - } - } - } -} - -output "connection_result" { - value = equinix_fabric_connection.fcr2profile.id -} diff --git a/modules/cloud-router-2-service-profile/terraform.tf b/modules/cloud-router-2-service-profile/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-2-service-profile/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-2-service-profile/terraform.tfvars.example b/modules/cloud-router-2-service-profile/terraform.tfvars.example deleted file mode 100644 index 52493859..00000000 --- a/modules/cloud-router-2-service-profile/terraform.tfvars.example +++ /dev/null @@ -1,16 +0,0 @@ -equinix_client_id = "Equnix_Client_Id" -equinix_client_secret = "Equinix_Client_Secret" -connection_name = "cloudRouter_gen_csp" -connection_type = "IP_VC" -notifications_type = "ALL" -notifications_emails = ["example@equinix.com"] -bandwidth = 50 -redundancy = "PRIMARY" # Can either be PRIMARY or SECONDARY -redundancy_group_uuid = "53e04795-e6da-4756-9462-8bdc9b1f96d3" #OPTIONAL -purchase_order_number = "1-323292" -aside_ap_type = "CLOUD_ROUTER" -fcr_uuid = "Fabric Cloud Router UUID" -zside_ap_type = "SP" -zside_ap_profile_type = "L2_PROFILE" -zside_location = "SV" -fabric_sp_name = "Ajith Ops User QnQ" diff --git a/modules/cloud-router-2-service-profile/variable.tf b/modules/cloud-router-2-service-profile/variable.tf deleted file mode 100644 index fa0bf74c..00000000 --- a/modules/cloud-router-2-service-profile/variable.tf +++ /dev/null @@ -1,16 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} -variable "connection_name" {} -variable "connection_type" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "bandwidth" {} -variable "redundancy" {} -variable "redundancy_group_uuid" {} -variable "purchase_order_number" {} -variable "aside_ap_type" {} -variable "fcr_uuid" {} -variable "zside_ap_type" {} -variable "zside_ap_profile_type" {} -variable "zside_location" {} -variable "fabric_sp_name" {} diff --git a/modules/cloud-router-connection/main.tf b/modules/cloud-router-connection/main.tf new file mode 100644 index 00000000..ae35376d --- /dev/null +++ b/modules/cloud-router-connection/main.tf @@ -0,0 +1,179 @@ +terraform { + required_providers { + equinix = { + source = "equinix/equinix" + version = "" + } + } +} +data "equinix_fabric_service_profiles" "zside" { + count = var.zside_ap_type == "SP" ? 1 : 0 + filter { + property = "/name" + operator = "=" + values = [var.zside_fabric_sp_name] + } +} +data "equinix_fabric_ports" "zside" { + count = var.zside_ap_type == "COLO" ? 1 : 0 + filters { + name = var.zside_port_name + } +} + + +resource "equinix_fabric_connection" "primary_cloud_router_connection" { + name = var.connection_name + type = var.connection_type + notifications { + type = var.notifications_type + emails = var.notifications_emails + } + additional_info = var.additional_info != [] ? var.additional_info : null + bandwidth = var.bandwidth + redundancy { priority = "PRIMARY" } + order { + purchase_order_number = var.purchase_order_number + } + a_side { + access_point { + type = var.aside_ap_type + router { + uuid = var.aside_fcr_uuid + } + } + } + dynamic "z_side" { + #ports z_side type + for_each = var.zside_ap_type == "COLO" ? [1] : [] + content { + access_point { + type = var.zside_ap_type + port { + uuid = data.equinix_fabric_ports.zside[0].id + } + link_protocol { + type = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type + vlan_tag = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type == "DOT1Q" ? var.zside_vlan_outer_tag : null + vlan_s_tag = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type == "QINQ" ? var.zside_vlan_outer_tag : null + vlan_c_tag = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type == "QINQ" ? var.zside_vlan_inner_tag : null + } + location { + metro_code = var.zside_location + } + } + } + } + dynamic "z_side" { + # Service Profile Z_Side Type + for_each = var.zside_ap_type == "SP" ? [1] : [] + content { + access_point { + type = var.zside_ap_type + authentication_key = var.zside_ap_authentication_key + seller_region = var.zside_seller_region + peering_type = var.zside_peering_type + profile { + type = var.zside_ap_profile_type + uuid = data.equinix_fabric_service_profiles.zside[0].id + } + location { + metro_code = var.zside_location + } + } + } + } + dynamic "z_side" { + #Network Z_Side Type + for_each = var.zside_ap_type == "NETWORK" ? [1] : [] + content { + access_point { + type= var.zside_ap_type + network { + uuid = var.zside_network_uuid + } + } + } + } +} + +resource "equinix_fabric_connection" "secondary_cloud_router_connection" { + count = var.secondary_connection_name != "" ? 1: 0 + name = var.secondary_connection_name + type = var.connection_type + notifications { + type = var.notifications_type + emails = var.notifications_emails + } + additional_info = var.additional_info != [] ? var.additional_info : null + bandwidth = var.secondary_bandwidth + redundancy { + priority = "SECONDARY" + group = one(equinix_fabric_connection.primary_cloud_router_connection.redundancy).group + } + order { + purchase_order_number = var.purchase_order_number + } + a_side { + access_point { + type = var.aside_ap_type + + router { + uuid = var.aside_sec_fcr_uuid + } + } + } + dynamic "z_side" { + #ports z_side type + for_each = var.zside_ap_type == "COLO" ? [1] : [] + content { + access_point { + type = var.zside_ap_type + port { + uuid = data.equinix_fabric_ports.zside[0].id + } + link_protocol { + type = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type + vlan_tag = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type == "DOT1Q" ? var.zside_vlan_outer_tag : null + vlan_s_tag = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type == "QINQ" ? var.zside_vlan_outer_tag : null + vlan_c_tag = one(data.equinix_fabric_ports.zside[0].data[0].encapsulation).type == "QINQ" ? var.zside_vlan_inner_tag : null + } + location { + metro_code = var.zside_location + } + } + } + } + dynamic "z_side" { + # Service Profile Z_Side Type + for_each = var.zside_ap_type == "SP" ? [1] : [] + content { + access_point { + type = var.zside_ap_type + authentication_key = var.zside_ap_authentication_key + seller_region = var.zside_seller_region + peering_type = var.zside_peering_type + profile { + type = var.zside_ap_profile_type + uuid = data.equinix_fabric_service_profiles.zside[0].id + } + location { + metro_code = var.zside_location + } + } + } + } + + dynamic "z_side" { + #Network Z_Side Type + for_each = var.zside_ap_type == "NETWORK" ? [1] : [] + content { + access_point { + type= var.zside_ap_type + network { + uuid = var.zside_network_uuid + } + } + } + } +} diff --git a/modules/cloud-router-connection/outputs.tf b/modules/cloud-router-connection/outputs.tf new file mode 100644 index 00000000..99e899aa --- /dev/null +++ b/modules/cloud-router-connection/outputs.tf @@ -0,0 +1,6 @@ +output "primary_connection_id" { + value = equinix_fabric_connection.primary_cloud_router_connection.id +} +output "secondary_connection_id" { + value = var.secondary_connection_name != "" ? equinix_fabric_connection.secondary_cloud_router_connection[0].id : null +} diff --git a/modules/cloud-router-connection/variables.tf b/modules/cloud-router-connection/variables.tf new file mode 100644 index 00000000..a0500f36 --- /dev/null +++ b/modules/cloud-router-connection/variables.tf @@ -0,0 +1,105 @@ +variable "connection_name" { + description = "Connection name. An alpha-numeric 24 characters string which can include only hyphens and underscores" + type = string +} +variable "connection_type" { + description = "Defines the connection type like VG_VC, EVPL_VC, EPL_VC, EC_VC, IP_VC, ACCESS_EPL_VC" + type = string + default = "" +} +variable "notifications_type" { + description = "Notification Type - ALL,CONNECTION_APPROVAL,SALES_REP_NOTIFICATIONS, NOTIFICATIONS" + type = string + +} +variable "notifications_emails" { + description = "Array of contact emails" + type = list(string) +} +variable "bandwidth" { + description = "Connection bandwidth in Mbps" + type = number +} +variable "purchase_order_number" { + description = "Purchase order number" + type = string +} +variable "aside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string +} +variable "aside_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier" + type = string +} +variable "zside_port_name" { + description = "Equinix Zside Port Name" + type = string + default = "" +} +variable "zside_ap_authentication_key" { + description = "Authentication key for provider based connections" + type = string + default = "" +} +variable "zside_ap_type" { + description = "Access point type - COLO, VD, VG, SP, IGW, SUBNET, GW" + type = string + default = "SP" +} +variable "zside_ap_profile_type" { + description = "Service profile type - L2_PROFILE, L3_PROFILE, ECIA_PROFILE, ECMC_PROFILE" + type = string + default = "L2_PROFILE" +} +variable "zside_location" { + description = "Access point metro code" + type = string + default = "SP" +} +variable "zside_vlan_outer_tag" { + description = "Access point protocol Vlan tag number for DOT1Q or QINQ connections" + default = "" +} +variable "zside_vlan_inner_tag" { + description = "Access point protocol Vlan tag number for QINQ connections" + default = "" +} +variable "zside_peering_type" { + description = "Access point peering type - PRIVATE, MICROSOFT, PUBLIC, MANUAL" + default = "PRIVATE" +} +variable "zside_network_uuid" { + description = "Network UUID" + default = "" +} +variable "zside_fabric_sp_name" { + description = "Equinix Service Profile Name" + type = string + default = "" +} +variable "zside_seller_region" { + description = "Access point seller region" + type = string + default = "" +} +variable "secondary_connection_name" { + description = "Secondary Connection name" + type = string + default = "" +} +variable "secondary_bandwidth" { + description = "Connection bandwidth in Mbps" + type = number + default = 50 +} +variable "aside_sec_fcr_uuid" { + description = "Equinix-assigned Fabric Cloud Router identifier for Secondary Connection" + type = string + default = "" +} +variable "additional_info" { + description = "Additional parameters required for some service profiles. It should be a list of maps containing 'key' and 'value e.g. `[{ key='asn' value = '65000'}, { key='ip' value = '192.168.0.1'}]`" + type = list(object({key = string, value = string})) + default = [] +} diff --git a/modules/cloud-router-multi-cloud/README.md b/modules/cloud-router-multi-cloud/README.md deleted file mode 100644 index 868a5e65..00000000 --- a/modules/cloud-router-multi-cloud/README.md +++ /dev/null @@ -1,109 +0,0 @@ -# ECX Fabric Layer2 MultiCloud Connection: FCR 2 AWS and Azure - -This example shows how to create Layer 2 Connection between FCR to AWS and Azure. - -## Adjust variables - -At minimum, you must set below variables in `terraform.tfvars` file: - -* `equinix_client_id` - Equinix client ID (consumer key), obtained after - registering app in the developer platform -* `equinix_client_secret` - Equinix client secret ID (consumer secret), - obtained same way as above - -`fcr_name` - Name of ECX Fabric Cloud Router on a-side , i.e. amcrh007-fcr -`fcr_type` - Fabric Cloud Router type -`fcr_location` - Fabric Cloud Router location -`fcr_project` - Fabric Cloud Router project -`fcr_account` - Fabric Cloud Router account -`fcr_package` - Fabric Cloud Router package type, i.e. PRO -`notifications_type` - notification type -`notifications_emails` - List of emails - - -`azure_connection_name` - The name of the Azure connection -`azure_connection_type` - Connection type, please refer to OAS schema for enum values. -`azure_notifications_type` - Notification type -`azure_notifications_emails` - List of emails -`azure_bandwidth` - Bandwidth in MBs -`azure_redundancy` - Port redundancy PRIMARY or SECONDARY -`azure_purchase_order_number` - Purchase order number applied to billing invoices for this connection. -`azure_peering_type` - Peering Type -`azure_aside_ap_type` - Access point type - -`azure_zside_ap_type` - Z side access point type -`azure_zside_ap_authentication_key` - AZURE authorization key, like c620477c-3f30-41e8-a0b9-cf324a12121d -`azure_zside_ap_profile_type` - Service profile type -`azure_zside_location` - Equinix Metro Code for the Z side access point -`azure_fabric_sp_name` - Service profile name like i.e. AZURE - -`azure_rp_name`- Name of Direct routing Protocol -`azure_rp_type`- Type of Direct routing Protocol entity, "DIRECT" -`azure_equinix_ipv4_ip` = Equinix Side IpV4 Address -`azure_equinix_ipv6_ip` = Equinix Side IpV6 Address - -`azure_bgp_rp_name` - Name of BGP routing Protocol -`azure_bgp_rp_type` - Type of BGP routing Protocol entity, "BGP" -`azure_bgp_customer_peer_ipv4` - Customer Side IpV4 Address -`azure_bgp_customer_peer_ipv6` - Customer Side IpV6 Address -`azure_bgp_enabled_ipv4` - Enable BGP IpV4 session from customer side -`azure_bgp_enabled_ipv6` - Enable BGP IpV6 session from customer side -`azure_bgp_customer_asn` - Customer ASN Number - -`aws_connection_name` - The name of the AWS connection -`aws_connection_type` - connection type, please refer schema -`aws_notifications_type` - notification type -`aws_notifications_emails` - List of emails -`aws_bandwidth` - bandwidth in MBs -`aws_redundancy` - Port redundancy -`aws_aside_ap_type` - Fabric Cloud Router type -`aws_zside_ap_type` - Z side access point type -`aws_zside_ap_authentication_key` - AWS authorization key, account number like 357848912121 -`aws_access_key` - AWS access key, like BQR12AHQKSYUTPBGHPIJ -`aws_secret_key` - AWS secret key, like 2qwrbYTUUIQWOOEIHDJSKbhikjhalpe -`aws_zside_ap_profile_type` - Service profile type -`aws_fabric_sp_name` - Service profile name, fetched based on Service Profile get call using Service Profile search schema -`aws_zside_location` - Seller location -`aws_seller_region` - Seller region code - -`aws_rp_name`- Name of Direct routing Protocol -`aws_rp_type`- Type of Direct routing Protocol entity, "DIRECT" -`aws_equinix_ipv4_ip` = Equinix Side IpV4 Address -`aws_equinix_ipv6_ip` = Equinix Side IpV6 Address - -`aws_bgp_rp_name` - Name of BGP routing Protocol -`aws_bgp_rp_type` - Type of BGP routing Protocol entity, "BGP" -`aws_bgp_customer_peer_ipv4` - Customer Side IpV4 Address -`aws_bgp_customer_peer_ipv6` - Customer Side IpV6 Address -`aws_bgp_enabled_ipv4` - Enable BGP IpV4 session from customer side -`aws_bgp_enabled_ipv6` - Enable BGP IpV6 session from customer side -`aws_bgp_customer_asn` - Customer ASN Number - -## Azure login - -Log in to Azure portal with an account that has permission to create necessary resources. - -Create an Azure ExpressRoute Circuit and use its Service Key as the Authentication Key in the examples. - -Bandwidth in Terraform must match the bandwidth of the ExpressRoute Circuit created in Azure. - -## AWS login - -Log in to AWS portal use account that has permission to create necessary resources. - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations for multi cloud connections can be found at examples/fabric/v4/cloudRouterConnectivity/MutliCloudConnection - -- Change directory into - `CD examples/fabric/v4/cloudRouterConnectivity/MutliCloudConnection` -- Initialize Terraform plugins - `terraform init` - -## Multi Cloud connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|--------------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates multi-cloud connection resources | -| READ | `terraform show` | Reads/Shows the current state of the multi-cloud connection resources | -| UPDATE | `terraform apply -refresh` | Updates the connections with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created multi-cloud connection resources | diff --git a/modules/cloud-router-multi-cloud/main.tf b/modules/cloud-router-multi-cloud/main.tf deleted file mode 100644 index b32c8450..00000000 --- a/modules/cloud-router-multi-cloud/main.tf +++ /dev/null @@ -1,213 +0,0 @@ -provider "equinix" { - client_id = var.equinix_client_id - client_secret = var.equinix_client_secret -} - -resource "equinix_fabric_cloud_router" "test" { - name = var.fcr_name - type = var.fcr_type - notifications { - type = var.notifications_type - emails = var.notifications_emails - } - order { - purchase_order_number = var.purchase_order_number - } - location { - metro_code = var.fcr_location - } - package { - code = var.fcr_package - } - project { - project_id = var.fcr_project - } - account { - account_number = var.fcr_account - } -} - -output "fcr_result" { - value = equinix_fabric_cloud_router.test.id -} - -data "equinix_fabric_service_profiles" "azure" { - filter { - property = "/name" - operator = "=" - values = [var.azure_fabric_sp_name] - } -} - -resource "equinix_fabric_connection" "fcr2azure" { - name = var.azure_connection_name - type = var.azure_connection_type - - notifications { - type = var.azure_notifications_type - emails = var.azure_notifications_emails - } - bandwidth = var.azure_bandwidth - redundancy { - priority = var.azure_redundancy - } - order { - purchase_order_number = var.azure_purchase_order_number - } - a_side { - access_point { - type = var.azure_aside_ap_type - router { - uuid = equinix_fabric_cloud_router.test.id - } - } - } - - z_side { - access_point { - type = var.azure_zside_ap_type - authentication_key = var.azure_zside_ap_authentication_key - peering_type = var.azure_peering_type - profile { - type = var.azure_zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.azure.id - } - location { - metro_code = var.azure_zside_location - } - } - } -} -output "azure_connection_name" { - value = equinix_fabric_connection.fcr2azure.name -} -output "azure_connection_id" { - value = equinix_fabric_connection.fcr2azure.id -} - -resource "equinix_fabric_routing_protocol" "azure-direct-protocol" { - connection_uuid = equinix_fabric_connection.fcr2azure.id - type = var.azure_rp_type - name = var.azure_rp_name - direct_ipv4 { - equinix_iface_ip = var.azure_equinix_ipv4_ip - } - direct_ipv6 { - equinix_iface_ip = var.azure_equinix_ipv6_ip - } -} - -output "azure_rp_direct_id" { - value = equinix_fabric_routing_protocol.azure-direct-protocol.id -} - -resource "equinix_fabric_routing_protocol" "azure-bgp-protocol" { - connection_uuid = equinix_fabric_connection.fcr2azure.id - type = var.azure_bgp_rp_type - name = var.azure_bgp_rp_name - bgp_ipv4 { - customer_peer_ip = var.azure_bgp_customer_peer_ipv4 - enabled = var.azure_bgp_enabled_ipv4 - } - bgp_ipv6 { - customer_peer_ip = var.azure_bgp_customer_peer_ipv6 - enabled = var.azure_bgp_enabled_ipv6 - } - customer_asn = var.azure_bgp_customer_asn - depends_on = [equinix_fabric_routing_protocol.azure-direct-protocol] -} - -output "azure_rp_bgp_id" { - value = equinix_fabric_routing_protocol.azure-bgp-protocol.id -} - - -data "equinix_fabric_service_profiles" "aws" { - filter { - property = "/name" - operator = "=" - values = [var.aws_fabric_sp_name] - } -} - -resource "equinix_fabric_connection" "fcr2aws" { - name = var.aws_connection_name - type = var.aws_connection_type - notifications { - type = var.aws_notifications_type - emails = var.aws_notifications_emails - } - additional_info = [{ "key" = "accessKey", "value" = var.aws_access_key }, { "key" = "secretKey", "value" = var.aws_secret_key }] - bandwidth = var.aws_bandwidth - redundancy { priority = var.aws_redundancy } - order { - purchase_order_number = var.aws_purchase_order_number - } - a_side { - access_point { - type = var.aws_aside_ap_type - router { - uuid = equinix_fabric_cloud_router.test.id - } - } - } - z_side { - access_point { - type = var.aws_zside_ap_type - authentication_key = var.aws_zside_ap_authentication_key - seller_region = var.aws_seller_region - profile { - type = var.aws_zside_ap_profile_type - uuid = data.equinix_fabric_service_profiles.aws.id - } - location { - metro_code = var.aws_zside_location - } - } - } -} - -output "aws_connection_name" { - value = equinix_fabric_connection.fcr2aws.name -} - -output "aws_connection_id" { - value = equinix_fabric_connection.fcr2aws.id -} - -resource "equinix_fabric_routing_protocol" "aws-direct-protocol" { - connection_uuid = equinix_fabric_connection.fcr2aws.id - type = var.aws_rp_type - name = var.aws_rp_name - direct_ipv4 { - equinix_iface_ip = var.aws_equinix_ipv4_ip - } - direct_ipv6 { - equinix_iface_ip = var.aws_equinix_ipv6_ip - } -} - -output "aws_rp_direct_id" { - value = equinix_fabric_routing_protocol.aws-direct-protocol.id -} - -resource "equinix_fabric_routing_protocol" "aws-bgp-protocol" { - connection_uuid = equinix_fabric_connection.fcr2aws.id - type = var.aws_bgp_rp_type - name = var.aws_bgp_rp_name - bgp_ipv4 { - customer_peer_ip = var.aws_bgp_customer_peer_ipv4 - enabled = var.aws_bgp_enabled_ipv4 - } - bgp_ipv6 { - customer_peer_ip = var.aws_bgp_customer_peer_ipv6 - enabled = var.aws_bgp_enabled_ipv6 - } - customer_asn = var.aws_bgp_customer_asn - - depends_on = [equinix_fabric_routing_protocol.aws-direct-protocol] -} - -output "aws_rp_bgp_id" { - value = equinix_fabric_routing_protocol.aws-bgp-protocol.id -} diff --git a/modules/cloud-router-multi-cloud/terraform.tf b/modules/cloud-router-multi-cloud/terraform.tf deleted file mode 100644 index fd41df1c..00000000 --- a/modules/cloud-router-multi-cloud/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} diff --git a/modules/cloud-router-multi-cloud/terraform.tfvars.example b/modules/cloud-router-multi-cloud/terraform.tfvars.example deleted file mode 100644 index a81ccdf8..00000000 --- a/modules/cloud-router-multi-cloud/terraform.tfvars.example +++ /dev/null @@ -1,79 +0,0 @@ -equinix_client_id = "MyEquinixClientId" -equinix_client_secret = "MyEquinixSecret" - -#FCR -fcr_name = "TERA_E2E_FCR" -fcr_type = "XF_ROUTER" -notifications_type = "ALL" -notifications_emails = ["example@equinix.com", "test1@equinix.com"] -purchase_order_number = "1-323290" -fcr_location = "SV" -fcr_package = "PRO" -fcr_project = "2916390007636552" -fcr_account = "201258" - -#Azure Connection -azure_connection_name = "FCR_2_AZURE" -azure_connection_type = "IP_VC" -azure_notifications_type = "ALL" -azure_notifications_emails = ["example@equinix.com"] -azure_bandwidth = 50 -azure_redundancy = "PRIMARY" -azure_purchase_order_number = "1-323292" -azure_peering_type = "PRIVATE" -azure_aside_ap_type = "CLOUD_ROUTER" - -azure_zside_ap_type = "SP" -azure_zside_ap_authentication_key = "Azure Express Route Service Key" -azure_zside_ap_profile_type = "L2_PROFILE" -azure_zside_location = "SV" -azure_fabric_sp_name = "Azure ExpressRoute" - -#Azure DIRECT RP -azure_rp_type = "DIRECT" -azure_rp_name = "FCR-Con-IP" -azure_equinix_ipv4_ip = "190.1.1.1/30" -azure_equinix_ipv6_ip = "190::1:1/126" - -#Azure BGP RP -azure_bgp_rp_type = "BGP" -azure_bgp_rp_name = "FCR-Con-BGP" -azure_bgp_customer_peer_ipv4 = "190.1.1.2" -azure_bgp_customer_peer_ipv6 = "190::1:2" -azure_bgp_enabled_ipv4 = true -azure_bgp_enabled_ipv6 = true -azure_bgp_customer_asn = "100" - -#AWS Connection -aws_connection_name = "FCR_2_AWS" -aws_connection_type = "IP_VC" -aws_notifications_type = "ALL" -aws_notifications_emails = ["example@equinix.com", "test1@equinix.com"] -aws_purchase_order_number = "1-323293" -aws_bandwidth = 50 -aws_redundancy = "SECONDARY" -aws_aside_ap_type = "CLOUD_ROUTER" - -aws_zside_ap_type = "SP" -aws_zside_ap_authentication_key = "AWS Authentication Key (Account Number)" -aws_access_key = "AWS Access Key" -aws_secret_key = "AWS Secret Key" -aws_zside_ap_profile_type = "L2_PROFILE" -aws_zside_location = "SV" -aws_seller_region = "us-west-1" -aws_fabric_sp_name = "AWS Direct Connect" - -#AWS DIRECT RP -aws_rp_type = "DIRECT" -aws_rp_name = "FCR-Con-IP" -aws_equinix_ipv4_ip = "192.68.100.1/30" -aws_equinix_ipv6_ip = "192::1:1/126" - -#AWS BGP RP -aws_bgp_rp_type = "BGP" -aws_bgp_rp_name = "FCR-Con-BGP" -aws_bgp_customer_peer_ipv4 = "192.68.100.2" -aws_bgp_customer_peer_ipv6 = "192::1:2" -aws_bgp_enabled_ipv4 = true -aws_bgp_enabled_ipv6 = true -aws_bgp_customer_asn = "100" diff --git a/modules/cloud-router-multi-cloud/variables.tf b/modules/cloud-router-multi-cloud/variables.tf deleted file mode 100644 index 97aebb1e..00000000 --- a/modules/cloud-router-multi-cloud/variables.tf +++ /dev/null @@ -1,71 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} - -variable "fcr_name" {} -variable "fcr_type" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "purchase_order_number" {} -variable "fcr_location" {} -variable "fcr_package" {} -variable "fcr_project" {} -variable "fcr_account" {} - -variable "azure_connection_name" {} -variable "azure_connection_type" {} -variable "azure_notifications_type" {} -variable "azure_notifications_emails" {} -variable "azure_bandwidth" {} -variable "azure_redundancy" {} -variable "azure_purchase_order_number" {} -variable "azure_peering_type" {} -variable "azure_aside_ap_type" {} - -variable "azure_zside_ap_type" {} -variable "azure_zside_ap_authentication_key" {} -variable "azure_zside_ap_profile_type" {} -variable "azure_zside_location" {} -variable "azure_fabric_sp_name" {} - -variable "azure_rp_type" {} -variable "azure_rp_name" {} -variable "azure_equinix_ipv4_ip" {} -variable "azure_equinix_ipv6_ip" {} - -variable "azure_bgp_rp_type" {} -variable "azure_bgp_rp_name" {} -variable "azure_bgp_customer_peer_ipv4" {} -variable "azure_bgp_customer_peer_ipv6" {} -variable "azure_bgp_enabled_ipv4" {} -variable "azure_bgp_enabled_ipv6" {} -variable "azure_bgp_customer_asn" {} - -variable "aws_notifications_type" {} -variable "aws_notifications_emails" {} -variable "aws_purchase_order_number" {} -variable "aws_connection_name" {} -variable "aws_connection_type" {} -variable "aws_bandwidth" {} -variable "aws_redundancy" {} -variable "aws_aside_ap_type" {} -variable "aws_zside_ap_type" {} -variable "aws_zside_ap_authentication_key" {} -variable "aws_access_key" {} -variable "aws_secret_key" {} -variable "aws_zside_ap_profile_type" {} -variable "aws_zside_location" {} -variable "aws_seller_region" {} -variable "aws_fabric_sp_name" {} - -variable "aws_rp_type" {} -variable "aws_rp_name" {} -variable "aws_equinix_ipv4_ip" {} -variable "aws_equinix_ipv6_ip" {} - -variable "aws_bgp_rp_type" {} -variable "aws_bgp_rp_name" {} -variable "aws_bgp_customer_peer_ipv4" {} -variable "aws_bgp_customer_peer_ipv6" {} -variable "aws_bgp_enabled_ipv4" {} -variable "aws_bgp_enabled_ipv6" {} -variable "aws_bgp_customer_asn" {} diff --git a/modules/port-2-google/README.md b/modules/port-2-google/README.md deleted file mode 100644 index a52d3a8b..00000000 --- a/modules/port-2-google/README.md +++ /dev/null @@ -1,51 +0,0 @@ -# ECX Fabric Layer2 Connection to Google - -This example shows how to create layer 2 connection between ECX Fabric port and Google Cloud. -Example covers **provisioning of both sides** of the connection. - -## Adjust variables - -At minimum, you must set below variables in `terraform.tfvars` file: - -- `equinix_client_id` - Equinix client ID (consumer key), obtained after registering app in the developer platform -- `equinix_client_secret` - Equinix client secret ID (consumer secret), obtained same way as above -- `fabric_sp_name` - Service profile name like i.e. **Google Cloud Partner Interconnect Zone 1** -- `equinix_port_name` - Name of ECX Fabric port that should be connected to Google, i.e. ops-user100-CX-SV5-NL-Qinq-BO-10G-SEC-JP-000 -- `connection_name` - the name of the connection -- `connection_type` - connection type, please refer schema -- `notifications_type` - notification type -- `notifications_emails` - List of emails -- `bandwidth` - bandwidth in MBs -- `redundancy` - Port redundancy -- `aside_ap_type` - Access point type -- `aside_port_uuid` - Port uuid, fetched based on port call using Port resource -- `aside_link_protocol_type` - link protocol type -- `aside_link_protocol_stag` - s tag number -- `aside_link_protocol_ctag` - c tag number -- `zside_ap_type` - Z side access point type -- `zside_ap_authentication_key` - Google authorization key following a pattern, like **9da09fe8-a33b-4457-ab7d-d91f83152276/us-west1/1** -- `zside_ap_profile_type` - Service profile type -- `zside_ap_profile_uuid` - Service profile uuid, fetched based on Service Profile get call using Service Profile search schema -- `zside_location` - Seller location -- `seller_region` - Seller region code - -## Google login - -Log in to Google portal use account that has permission to create necessary resources. - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations for port2google connection can be found at examples/fabric/v4/portConnectivity/google/. - -- Change directory into - `CD examples/fabric/v4/portConnectivity/google/` -- Initialize Terraform plugins - `terraform init` - -## Port to Google connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|--------------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a port2google connection resource | -| READ | `terraform show` | Reads/Shows the current state of the port2google connection resource | -| UPDATE | `terraform apply -refresh` | Updates the port2google with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created port2google connection resource | diff --git a/modules/port-2-google/terraform.tf b/modules/port-2-google/terraform.tf deleted file mode 100644 index 2dc81d8b..00000000 --- a/modules/port-2-google/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source = "equinix/equinix" - } - } -} \ No newline at end of file diff --git a/modules/port-2-ibm2/README.md b/modules/port-2-ibm2/README.md deleted file mode 100644 index 70e20696..00000000 --- a/modules/port-2-ibm2/README.md +++ /dev/null @@ -1,52 +0,0 @@ -# ECX Fabric Layer2 Redundant Connection to IBM 2 - -This example shows how to create Layer 2 Connection between ECX Fabric ports and IBM2 Cloud. - -## Adjust variables - -At minimum, you must set below variables in `terraform.tfvars` file: - -* `equinix_client_id` - Equinix client ID (consumer key), obtained after - registering app in the developer platform -* `equinix_client_secret` - Equinix client secret ID (consumer secret), - obtained same way as above - -`connection_name` - The name of the connection -`connection_type` - Connection type, please refer to OAS schema for enum values. -`notifications_type` - Notification type -`notifications_emails` - List of emails -`bandwidth` - Bandwidth in MBs -`redundancy` - Port redundancy -`purchase_order_number` - Purchase order number applied to billing invoices for this connection. -`aside_ap_type` - Access point type -`aside_link_protocol_type` - Link protocol type -`aside_pri_link_protocol_tag` - Tag number -`zside_ap_type` - Z side access point type -`zside_ap_authentication_key` - IBM authorization key (Account Id), like 6if92b31d921499f903592cd816f6aw1 -`zside_ap_profile_type` - Service profile type -`zside_location` - Equinix Metro Code for the Z side access point -`fabric_sp_name` - Service profile name like i.e. AZURE -`equinix_port_name` - Name of ECX Fabric Port -`seller_asn` - Seller ASN Number -`seller_region` - Seller Region - -## IBM login - -Log in to IBM portal with an account that has permission to create necessary resources. - -## Initialize -- First step is to initialize the terraform directory/resource we are going to work on. - In the given example, the folder to perform CRUD operations for port2ibm2 redundant connections can be found at examples/fabric/v4/portConnectivity/ibm/ibm2. - -- Change directory into - `CD examples/fabric/v4/portConnectivity/ibm/ibm2` -- Initialize Terraform plugins - `terraform init` - -## Port to IBM2 connection : Create, Read, Update and Delete(CRUD) operations -Note: `–auto-approve` command does not prompt the user for validating the applying config. Remove it to get a prompt to confirm the operation. - -| Operation | Command | Description | -|:----------|:---------------------------------:|---------------------------------------------------------------------------:| -| CREATE | `terraform apply –auto-approve` | Creates a port2ibm2 connection resources | -| READ | `terraform show` | Reads/Shows the current state of the port2ibm2 connection resources | -| UPDATE | `terraform apply -refresh` | Updates the connections with values provided in the terraform.tfvars file | -| DELETE | `terraform destroy –auto-approve` | Deletes the created port2ibm2 connection resources | diff --git a/modules/port-2-ibm2/terraform.tf b/modules/port-2-ibm2/terraform.tf deleted file mode 100644 index b5f55a7f..00000000 --- a/modules/port-2-ibm2/terraform.tf +++ /dev/null @@ -1,7 +0,0 @@ -terraform { - required_providers { - equinix = { - source="equinix/equinix" - } - } -} diff --git a/modules/port-2-ibm2/variables.tf b/modules/port-2-ibm2/variables.tf deleted file mode 100644 index b8ddcb5a..00000000 --- a/modules/port-2-ibm2/variables.tf +++ /dev/null @@ -1,20 +0,0 @@ -variable "equinix_client_id" {} -variable "equinix_client_secret" {} -variable "connection_name" {} -variable "connection_type" {} -variable "notifications_type" {} -variable "notifications_emails" {} -variable "bandwidth" {} -variable "redundancy" {} -variable "purchase_order_number" {} -variable "aside_ap_type" {} -variable "aside_link_protocol_type" {} -variable "aside_link_protocol_tag" {} -variable "zside_ap_type" {} -variable "zside_ap_authentication_key" {} -variable "zside_ap_profile_type" {} -variable "zside_location" {} -variable "fabric_sp_name" {} -variable "equinix_port_name" {} -variable "seller_asn" {} -variable "seller_region" {}