Update main.tf - #4
Conversation
WalkthroughChanged the value type of the "kubernetes.io/role/elb" tag in the VPC module’s public_subnet_tags from numeric 1 to string "1" in main.tf. No other changes. Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Pre-merge checks (2 passed, 1 inconclusive)❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
Poem
✨ Finishing Touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Whoops! Looks like your Terrateam trial has expired. Sign up for a subscription at https://terrateam.io/billing/subscribe. If you think this is a mistake, please reach out to support@terrateam.io or ping us on Slack. |
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
main.tf (1)
84-96: Remove addon_version pins from aws_eks_addon resources
Pinned versions (ebs-csi v1.39.0-eksbuild.1, kube-proxy v1.31.3-eksbuild.2, vpc-cni v1.19.2-eksbuild.1, coredns v1.11.4-eksbuild.2) may be incompatible with Kubernetes 1.32; omitaddon_versionto let EKS select the recommended version—or if you must pin, verify viaaws eks describe-addon-versions.
🧹 Nitpick comments (1)
main.tf (1)
48-51: Heads-up: AL2 node AMIs are nearing end of life for new releases.AL2 is supported through Kubernetes 1.32 with EKS AMI updates ending November 26, 2025. Consider planning a move to AL2023 or Bottlerocket for future upgrades.
Ref: EKS AL2 deprecation FAQs. (docs.amazonaws.cn)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
main.tf(1 hunks)
🔇 Additional comments (1)
main.tf (1)
33-34: Good fix: tag value should be a string.AWS tags are strings; the AWS Load Balancer Controller expects public subnets to have kubernetes.io/role/elb with value "1". Your change aligns with the documented requirement.
See: AWS re:Post and AWS LBC docs. (repost.aws, kubernetes-sigs.github.io)
| "kubernetes.io/cluster/your_cluster_name" = "shared" | ||
| "kubernetes.io/role/elb" = 1 | ||
| "kubernetes.io/role/elb" = "1" | ||
| } |
There was a problem hiding this comment.
Cluster-name tag mismatch will break subnet auto-discovery.
The subnet tag uses "your_cluster_name" but the EKS cluster_name is "mycluster". For AWS LBC auto-discovery, the kubernetes.io/cluster/ tag must match the actual cluster name.
Proposed change (keep the name in one place to avoid drift):
+locals {
+ cluster_name = "mycluster"
+}
...
- cluster_name = "mycluster"
+ cluster_name = local.cluster_name
...
- "kubernetes.io/cluster/your_cluster_name" = "shared"
+ "kubernetes.io/cluster/${local.cluster_name}" = "shared"Refs: AWS re:Post guidance and AWS LBC docs on required tags. (repost.aws, kubernetes-sigs.github.io)
Also applies to: 43-46
Summary by CodeRabbit