Skip to content

Commit 56bc4cd

Browse files
and-babkinmidnight47
authored andcommitted
fix: network policy for keda (#338)
Co-authored-by: midnight47 <[email protected]>
1 parent fa2fd4d commit 56bc4cd

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

terraform/layer2-k8s/eks-keda.tf

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,32 @@ module "keda_namespace" {
5252
}
5353
]
5454
}
55+
},
56+
{
57+
name = "allow-control-plane"
58+
policy_types = ["Ingress"]
59+
pod_selector = {
60+
match_expressions = {
61+
key = "app"
62+
operator = "In"
63+
values = ["keda-operator-metrics-apiserver"]
64+
}
65+
}
66+
ingress = {
67+
ports = [
68+
{
69+
port = "6443"
70+
protocol = "TCP"
71+
}
72+
]
73+
from = [
74+
{
75+
ip_block = {
76+
cidr = "0.0.0.0/0"
77+
}
78+
}
79+
]
80+
}
5581
}
5682
]
5783
}

0 commit comments

Comments
 (0)