Skip to content

Commit

Permalink
chore: Fix Linter issues
Browse files Browse the repository at this point in the history
  • Loading branch information
alexeyovriakh committed Feb 8, 2024
1 parent a51ff0b commit 4635274
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/services/eks/locals.tf
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
locals {
api_enabled_clusters = [
for cluster in data.aws_eks_cluster.clusters :
cluster if contains(["API", "API_AND_CONFIG_MAP"], cluster.access_config.0.authentication_mode) && (var.onboard_all_clusters || contains(var.clusters, cluster.name))
cluster if contains(["API", "API_AND_CONFIG_MAP"], cluster.access_config[0].authentication_mode) && (var.onboard_all_clusters || contains(var.clusters, cluster.name))
]

sysdig_cidrs = ["54.218.164.215/32", "54.244.190.180/32", "44.232.85.27/32"]
clusters = {
for cluster in local.api_enabled_clusters : cluster.name => cluster
// Only onboard public clusters or clusters that Sysdig has access to
if cluster.vpc_config.0.endpoint_public_access && (contains(cluster.vpc_config.0.public_access_cidrs, "0.0.0.0/0") || contains(cluster.vpc_config.0.public_access_cidrs, local.sysdig_cidrs[0]))
if cluster.vpc_config[0].endpoint_public_access && (contains(cluster.vpc_config[0].public_access_cidrs, "0.0.0.0/0") || contains(cluster.vpc_config[0].public_access_cidrs, local.sysdig_cidrs[0]))
}

eks_view_policy = "arn:aws:eks::aws:cluster-access-policy/AmazonEKSViewPolicy"
Expand Down

0 comments on commit 4635274

Please sign in to comment.