Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/josephphyo/terraform-aws-alb

Terraform AWS ALB
https://github.com/josephphyo/terraform-aws-alb

aws terraform terraform-module

Last synced: 4 days ago
JSON representation

Terraform AWS ALB

Awesome Lists containing this project

README

        

## AWS ALB Terraform module
#### Terraform module which creates ALB with Target Group resources on AWS.

##### Usage

```
module "alb" {
source = "josephphyo/alb/aws"

instance_sg_name = "regional-ec2-sg"
instance_sg_vpc_id = "vpc-abcd5678"
ins_subnet_id = "subnet-abcd5678"
lb_name = "regional-frontend-lb"
lb_sg_name = "regional-lb-sg"
lb_sg_vpc_id = "vpc-abcd5678"
lb_subnet_mapping_1 = "subnet-abcd5678"
lb_subnet_mapping_2 = "subnet-abcd5678"
tg_name = "regional-alb-tg"
tg_vpc_id = "vpc-abcd5678"
}

```

##### Requirements

| Name | Version |
|------|---------|
| [terraform](#requirement\_terraform) | ~> v1.0.0 |
| [aws](#requirement\_aws) | ~> 3.48.0 |

## Providers

| Name | Version |
|------|---------|
| [aws](#provider\_aws) | ~> 3.48.0 |

## Modules

No modules.

## Resources

| Name | Type |
|------|------|
| [aws_instance.regional_webserver](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/instance) | resource |
| [aws_lb.regional_lb](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/lb) | resource |
| [aws_lb_listener.front_end](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/lb_listener) | resource |
| [aws_lb_target_group.regional_lb_tg](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/lb_target_group) | resource |
| [aws_lb_target_group_attachment.regional_lb_tg_attach](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/lb_target_group_attachment) | resource |
| [aws_security_group.regional_instance_sg](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/security_group) | resource |
| [aws_security_group.regional_lb_sg](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/security_group) | resource |
| [aws_ami.ubuntu](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/ami) | data source |

## Inputs

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| [ingress\_cidr](#input\_ingress\_cidr) | n/a | `list(string)` |

[
"0.0.0.0/0"
]
| no |
| [ins\_count](#input\_ins\_count) | n/a | `number` | `1` | no |
| [ins\_subnet\_id](#input\_ins\_subnet\_id) | n/a | `string` | n/a | yes |
| [instance\_sg\_name](#input\_instance\_sg\_name) | n/a | `string` | n/a | yes |
| [instance\_sg\_vpc\_id](#input\_instance\_sg\_vpc\_id) | n/a | `string` | n/a | yes |
| [instance\_type](#input\_instance\_type) | n/a | `string` | `"t3.micro"` | no |
| [internal\_lb](#input\_internal\_lb) | n/a | `bool` | `false` | no |
| [lb\_name](#input\_lb\_name) | n/a | `string` | n/a | yes |
| [lb\_sg\_name](#input\_lb\_sg\_name) | n/a | `string` | n/a | yes |
| [lb\_sg\_vpc\_id](#input\_lb\_sg\_vpc\_id) | n/a | `string` | n/a | yes |
| [lb\_subnet\_mapping\_1](#input\_lb\_subnet\_mapping\_1) | n/a | `string` | n/a | yes |
| [lb\_subnet\_mapping\_2](#input\_lb\_subnet\_mapping\_2) | n/a | `string` | n/a | yes |
| [lb\_type](#input\_lb\_type) | n/a | `string` | `"application"` | no |
| [tg\_att\_count](#input\_tg\_att\_count) | n/a | `number` | `1` | no |
| [tg\_name](#input\_tg\_name) | n/a | `string` | n/a | yes |
| [tg\_vpc\_id](#input\_tg\_vpc\_id) | n/a | `string` | n/a | yes |

## Outputs

| Name | Description |
|------|-------------|
| [regional\_alb\_dns](#output\_regional\_alb\_dns) | Regional Application Load Balancer DNS |