Giter Club home page Giter Club logo

terraform-module-aws-vpc-subnet's Introduction

Terraform Module: terraform-module-aws-vpc-subnet

Terraform module for AWS VPC Subnet


Code : Stable

This is a stable example. It should successfully build out of the box

This examples does is built on Construct Libraries marked "Stable" and does not have any infrastructure prerequisites to build.


General

This module can be used to deploy a VPC Subnet on AWS Cloud Provider......


Prerequisites

This module needs Terraform 0.12.23 or newer. You can download the latest Terraform version from here.


Features Branches

Below we are able to check the resources that are being created as part of this module call:

  • VPC Subnet

Usage

Using this repo

To use this module, add the following call to your code:

  • Sample Code:
module "vpc_subnet" {
  source = "git::https://github.com/nitinda/terraform-module-aws-vpc-subnet.git?ref=master"


  vpc_id     = var.vpc_id
  cidr_block = "172.2.0.0/24"
  tags       = {
    Environment = "prod"
    Project     = "POC"
  }

}
module "vpc_subnet" {
  source = "git::https://github.com/nitinda/terraform-module-aws-vpc-subnet.git?ref=master"


  vpc_id     = var.vpc_id
  availability_zone = "eu-central-1c"
  cidr_block = "172.2.0.0/24"
  tags       = {
    Environment = "prod"
    Project     = "POC"
  }

}
module "public_1a" {
  source = "git::https://github.com/nitinda/terraform-module-aws-vpc-subnet.git?ref=master"

  vpc_id            = module.vpc.id
  cidr_block        = "10.1.0.0/16"
  availability_zone = "eu-central-1a"
  tags       = merge(
    var.common_tags,
    {
      Environment = "prod"
      Name        = "vpc-subnet-public-1a"
    }
  )
}
module "public_1a" {
  source = "git::https://github.com/nitinda/terraform-module-aws-vpc-subnet.git?ref=master"

  vpc_id               = module.vpc.id
  cidr_block           = "10.1.0.0/16"
  availability_zone_id = "euc1-az2"
  tags       = merge(
    var.common_tags,
    {
      Environment = "prod"
      Name        = "vpc-subnet-public-1a"
    }
  )
}

Inputs

The variables required in order for the module to be successfully called from the deployment repository are the following:

Variable Description Type Argument Status
availability_zone The AZ for the subnet string Optional
(Default - null)
availability_zone_id The AZ ID of the subnet string Optional
(Default - null)
cidr_block The CIDR block for the subnet string Required
ipv6_cidr_block The IPv6 network range for
the subnet, in CIDR notation
string Optional
(Default - null)
map_public_ip_on_launch Specify true to indicate that
instances launched into the subnet
should be assigned a public IP address
bool Optional
(Default - false)
assign_ipv6_address_on_creation Specify true to indicate that network interfaces
created in the specified subnet should be
assigned an IPv6 address
bool Optional
(Default - false)
vpc_id The VPC ID string Required
tags A mapping of tags to assign to the resource map(string) Required

Outputs

General

This module has the following outputs:

  • arn
  • id

Usage

In order for the variables to be accessed at module level please use the syntax below:

module.<module_name>.<output_variable_name>

The output variable is able to be accessed through terraform state file using the syntax below:

data.terraform_remote_state.<layer_name>.<output_variable_name>

Authors

Module maintained by Module maintained by the - Nitin Das

terraform-module-aws-vpc-subnet's People

Contributors

nitinda avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.