-
Notifications
You must be signed in to change notification settings - Fork 14
/
discovery.tf
28 lines (24 loc) · 839 Bytes
/
discovery.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
resource "aws_ec2_tag" "public_shared_subnet" {
for_each = toset([for s in data.aws_subnet.public : s.id])
resource_id = each.key
key = "kubernetes.io/cluster/${local.cluster_id}"
value = "shared"
}
resource "aws_ec2_tag" "public_lb" {
for_each = toset([for s in data.aws_subnet.public : s.id])
resource_id = each.key
key = "kubernetes.io/role/elb"
value = 1
}
resource "aws_ec2_tag" "private_shared_subnet" {
for_each = toset([for s in data.aws_subnet.private : s.id])
resource_id = each.key
key = "kubernetes.io/cluster/${local.cluster_id}"
value = "shared"
}
resource "aws_ec2_tag" "private_lb" {
for_each = toset([for s in data.aws_subnet.private : s.id])
resource_id = each.key
key = "kubernetes.io/role/internal-elb"
value = 1
}