Skip to content

p-devops/terraform-aws-consumer-elb

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Consumer ELB Module

This repo contains a Module to deploy a Elastic Load Balancer (ELB) on AWS using Terraform.

ELB Example

This Module works well with the following related modules:

  • Consumer EC2 Module

Who maintains and approves this module?

This module is maintained by the Organization's Infrastructure Team. Email [email protected] for more info.

Version Description Security Team Approval? Approver Approval Date
v1.1 closed firewall ports Yes John Doe 01/01/2019
v1.0 Initial ELB No N/A N/A

Usage

module "elb" {
  source  = "app.terraform.io/<YOURTFEORGNAME>/consumer-elb/aws"
  version = "1.13"
  name = "${var.name}-elb"
  environment = "${var.environment}"
  
  # ELB attachments
  number_of_instances = "${var.number_of_instances}"
  instances           = ["${module.ec2_instances.id}"]
}
  
module "ec2_instances" {
  source = "app.terraform.io/<YOURTFEORGNAME>/consumer-ec2-instance/aws"
  version = "1.4"
  name                        = "${var.name}-ec2"
  instance_count = "${var.number_of_instances}"
}

Inputs

Name Description Type Default Required
environment Choose:
dev
stage
prod
string - yes
instances List of instances ID to place in the ELB pool list <list> yes
name The name of the ELB string - yes
number_of_instances Number of instances to attach to ELB string 2 no

Outputs

This module contains no outputs.

Name Description

Configurations Baked into Module

Name Description
security group Ingress: Allow TCP port 80 from 0.0.0.0/0
listener lb_port = 80 lb_protocol = "http" instance_port = "8080" instance_protocol = "http"
health check healthy_threshold = 2 unhealthy_threshold = 2 timeout = 3 interval = 30 target = "HTTP:8080/"

Further Reading

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • HCL 100.0%