-
-
Notifications
You must be signed in to change notification settings - Fork 259
/
main.tf
45 lines (33 loc) · 1.2 KB
/
main.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
################################################################################
# Classic Load Balancer
################################################################################
module "elb" {
source = "./modules/elb"
create_elb = var.create_elb
name = var.name
name_prefix = var.name_prefix
subnets = var.subnets
security_groups = var.security_groups
internal = var.internal
cross_zone_load_balancing = var.cross_zone_load_balancing
idle_timeout = var.idle_timeout
connection_draining = var.connection_draining
connection_draining_timeout = var.connection_draining_timeout
listener = var.listener
access_logs = var.access_logs
health_check = var.health_check
tags = merge(
var.tags,
{ "Name" = var.name },
)
}
################################################################################
# Classic Load Balancer Attachment
################################################################################
module "elb_attachment" {
source = "./modules/elb_attachment"
create_attachment = var.create_elb
number_of_instances = var.number_of_instances
elb = module.elb.elb_id
instances = var.instances
}