Skip to content

Latest commit

 

History

History

vpe

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

Virtual Endpoint Gateway Module Example

This module is used to create Virtual Endpoint Gateway and IPs

Example Usage

data "ibm_is_vpc" "vpc" {
  count = var.create_endpoint_gateway ? 1 : 0
  name  = var.vpc
}

data "ibm_resource_group" "resource_group" {
  name = (var.resource_group != null ? var.resource_group : "default")
}

module "vpe" {
  source = "terraform-ibm-modules/vpc/ibm//modules/vpe"

  create_endpoint_gateway = var.create_endpoint_gateway
  name                    = var.name
  vpc_id                  = var.create_endpoint_gateway ? data.ibm_is_vpc.vpc[0].id : null
  resource_group_id       = data.ibm_resource_group.resource_group.id
  target                  = var.target
  ips                     = var.ips
  tags                    = var.tags
  endpoint_gateway        = var.endpoint_gateway
  reserved_ips            = var.reserved_ips
}

Requirements

Name Version
terraform >= 1.9.0
ibm >= 1.64.0, <2.0.0

Modules

No modules.

Resources

Name Type
ibm_is_virtual_endpoint_gateway.endpoint_gateway resource
ibm_is_virtual_endpoint_gateway_ip.virtual_endpoint_gateway_ips resource
ibm_is_virtual_endpoint_gateway.vpe_ds data source

Inputs

Name Description Type Default Required
create_endpoint_gateway True to create new endpoint gateway. False if endpoint gateway is already existing and endpoint gateway ips are to be added bool n/a yes
endpoint_gateway Existing Enpoint Gateway's Name to which Reserved IPs are to be attached string null no
ips Gateway IPs
list(object({
id = string
name = string
subnet = string
}))
[] no
name Name of the new Endpoint Gateway string null no
reserved_ips List of New reserved IPs to the Endpoint Gateway
list(object({
reserved_ip = string
}))
[] no
resource_group_id Resource group ID string null no
tags List of Tags for the Endpoint Gateway list(string) [] no
target Gateway target
list(object({
resource_type = string
name = string
crn = string
}))
[] no
vpc_id VPC ID of the new Endpoint Gateway string null no

Outputs

Name Description
endpoint_gateway_id The ID of the endpoint gateway
endpoint_gateway_ips The ID of the endpoint gateway IPs
endpoint_gateway_target The ID of the endpoint gateway target
gateway_reserved_ips All the Gateway Reserved IPs