Skip to content

Latest commit

 

History

History

gcve-service-networking

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

GCVE Service Networking Module

This module contains the terraform to create and deploy a GCVE Service Networking

Requirements

Name Version
terraform >= 1.5.3
google >= 4.35.0
google-beta >= 4.71.0

Usage

Basic usage of this module is as follows:

module "example" {
	 source  = "github.com/GoogleCloudPlatform/gcve-iac-foundations//modules/gcve-service-networking"

	 # Required variables
	 project_id  = "<PROJECT_ID>"
	 region  = "<REGION>"
	 network_name  = "<GCP_NETWORK_NAME>"
	 pc_location  = "<PRIVATE_CONNECTION_LOCATION>"
	 create_gcve_network  = "<CREATE_GCVE_NETWORK>"
	 gcve_connection_name  = "<GCVE_CONNECTION_NAME>"
	 gcve_network_location  = "<GCVE_NETWORK_LOCATION>"
	 gcve_network_name  = "<GCVE_NETWORK_NAME>"
	 primary_private_ip_alloc  = "<PRIMARY_PRIVATE_IP_ALLOC_NAME>"
	 private_ip_allocation_details  = "<PRIVATE_IP_ALLOC_DETAILS>"

	 # Optional variables
	 address_purpose  = "VPC_PEERING"
	 address_type  = "INTERNAL"
	 auto_create_subnetworks  = false
	 create_network  = true
	 delete_default_internet_gateway_routes  = false
	 gcve_network_description  = ""
	 gcve_network_type  = "LEGACY"
	 mtu  = 0
	 network_description  = ""
	 pc_connection_type  = "PRIVATE_SERVICE_ACCESS"
	 pc_description  = "gcve_service_networking"
	 pc_routing_mode  = "GLOBAL"
	 peering  = "servicenetworking-googleapis-com"
	 routing_mode  = "GLOBAL"
	 secondary_ranges  = {}
	 service  = "servicenetworking.googleapis.com"
	 subnets  = []
}

Resources

Name Type
google-beta_google_vmwareengine_network.gcve_network resource
google_compute_global_address.private_ip_alloc resource
google_compute_network.network resource
google_compute_network_peering_routes_config.peering_routes resource
google_compute_subnetwork.subnetwork resource
google_service_networking_connection.gcve_psa resource
google-beta_google_vmwareengine_network.gcve_network data source
google_compute_network.network data source
google_compute_network_peering.servicenetworking data source

Inputs

Name Description Type Default Required
address_purpose Purpose value to use in google_compute_global_address resource string "VPC_PEERING" no
address_type Address type value to use in google_compute_global_address resource string "INTERNAL" no
auto_create_subnetworks When set to true, the network is created in 'auto subnet mode' and it will create a subnet for each region automatically across the 10.128.0.0/9 address range. When set to false, the network is created in 'custom subnet mode' so the user can explicitly connect subnetwork resources. bool false no
create_gcve_network Set to true to create google vmwareengine network bool n/a yes
create_network If set to true, new VPC will be created bool true no
delete_default_internet_gateway_routes If set, ensure that all routes within the network specified whose names begin with 'default-route' and with a next hop of 'default-internet-gateway' are deleted bool false no
gcve_connection_name the GCVE Private Connection ID string n/a yes
gcve_network_description Description for the VMware Engine network string "" no
gcve_network_location The location where the VMwareEngineNetwork should reside string n/a yes
gcve_network_name The ID of the VMware Engine Network string n/a yes
gcve_network_type VMware Engine network type string "LEGACY" no
mtu The network MTU (If set to 0, meaning MTU is unset - defaults to '1460'). Recommended values: 1460 (default for historic reasons), 1500 (Internet default), or 8896 (for Jumbo packets). Allowed are all values in the range 1300 to 8896, inclusively. number 0 no
network_description Description for the GCP Network string "" no
network_name The name of the network being created string n/a yes
pc_connection_type Connection Type for GCVE Private Connection string "PRIVATE_SERVICE_ACCESS" no
pc_description Description for the Private Connection string "gcve_service_networking" no
pc_location The region to create the private connection string n/a yes
pc_routing_mode The routing mode of Private Connection string "GLOBAL" no
peering Peering value to use in google_compute_network_peering_routes_config resource string "servicenetworking-googleapis-com" no
primary_private_ip_alloc Primary Private IP Allocation which can be used for GCVE PSA Connection string n/a yes
private_ip_allocation_details Private IP Allocation details to Create Compute Global Address
map(object({
name = string,
address = string,
prefix_length = number
}))
n/a yes
project_id Project to create GCVE Service networking Resources string n/a yes
region The region to use string n/a yes
routing_mode The network routing mode (default 'GLOBAL') string "GLOBAL" no
secondary_ranges Secondary ranges that will be used in some of the subnets map(list(object({ range_name = string, ip_cidr_range = string }))) {} no
service Service value to use in google_service_networking_connection resource string "servicenetworking.googleapis.com" no
subnets The list of subnets being created list(map(string)) [] no

Outputs

Name Description
gcve_network_details GCVE Network Details
gcve_network_name GCVE Network Name
gcve_service_network_connection GCVE Service Network Connection
network_id The ID of the VPC being created
network_name The name of the VPC being created
network_self_link The URI of the VPC being created
peer_network_project_id Peer Network Project ID
peering_route_config Peering Route Config
private_ip_alloc_addresses Address of Private IP Allocations used for Peering
private_ip_alloc_details Names of Private IP Allocations for Peering
private_ip_alloc_ids ID of Private IP Allocations used for Peering
private_ip_alloc_names Names of Private IP Allocations used for Peering
private_ip_alloc_self_link Self Link of Private IP Allocations used for Peering
subnets The created subnet resources