Skip to content

Latest commit

 

History

History
90 lines (57 loc) · 6.21 KB

File metadata and controls

90 lines (57 loc) · 6.21 KB

Multizone VPC

This module creates a multizone VPC in a single region in 3 zones. It will create an example ACL and can optionally create public gateways for each zone.

Multizone VPC

Table of Contents

  1. VPC
  2. Subnets
  3. Public Gateway
  4. Access Control List (ACL)
  5. Module Variables
  6. Outputs
  7. As a Module in a Larger Architecture

VPC

This module creates a VPC in a single region inside a resource group.

Use IBM Cloud™ Virtual Private Cloud to create your own space in IBM Cloud™. A virtual private cloud (VPC) is a secure, isolated virtual network that combines the security of a private cloud with the availability and scalability of IBM's public cloud. 1

VPC Specific Variables

  • classic_access - Can be true or false.

  • You can set up access from a VPC to your IBM Cloud classic infrastructure, including Direct Link connectivity. One VPC per region can communicate with classic resources.2

More Info


Subnets

This module creates any of number of subnets in each of up to 3 geographic zones in the region where the VPC was created.

Each subnet consists of a specified IP address range (CIDR block). Subnets are bound to a single zone, and they cannot span multiple zones or regions. Subnets in the same VPC are connected to each other. 3

Subnet Specific Variables

  • cidr_blocks - List of IP ranges - A list of IP address ranges within the VPC where the subnet will be created. There must be a cidr block for each subnet created. - Cannot be a reserved IP address - If no CIDR blocks are provided, it will create subnets with 256 total ipv4 addresses.

Public Gateway

This module can optionally create public gateways attached to the subnets.

A Public Gateway enables a subnet and all its attached virtual server instances to connect to the internet. Subnets are private by default. After a subnet is attached to the public gateway, all instances in that subnet can connect to the internet. Although each zone has only one public gateway, the public gateway can be attached to multiple subnets.4


Access Control List

This module creates an ACL and attaches it to the subnets

You can use an access control list (ACL) to control all incoming and outgoing traffic in IBM Cloud™ Virtual Private Cloud. An ACL is a built-in, virtual firewall, similar to a security group. In contrast to security groups, ACL rules control traffic to and from the subnets, rather than to and from the instances.5


Module Variables

Variable Type Description Default
ibmcloud_api_key sting The IBM Cloud platform API key needed to deploy IAM enabled resources
unique_id string A unique prefix for the apps. Must begin with a letter. multizone-vpc
ibm_region string IBM Cloud region where all resources will be deployed
resource_group string Name of resource group to create VPC asset-development
generation number Generation for VPC
classic_access bool Enable VPC Classic Access. Note: only one VPC per region can have classic access false
enable_public_gateway bool Enable public gateways, true or false false
cidr_blocks list A list of tier subnet CIDR blocks. If no CIDRs are provided, the subnets will be created with 256 total ipv4 addresses `["172.16.1.128/27","172.16.3.128/27","172.16.5.128/27"]

Outputs

Name Value
subnet_ids List of subnets created by module
acl_id ID of ACL Created
tier_3_subnet_ids List of subnets created by module for tier 3
vpc_id ID of VPC created