I'm trying to use Kubernetes cluster-autoscaler in EKS, and I'd like to ensure fresh nodes are always created with the latest recommended AMI (so that OS patches don't have to wait for a manual CI/CD re-run). I also want to be able to pass custom kubelet arguments (e.g., to enable SSD swap memory).
I tried terraforming a managed node group (a wrapper around an auto-scaling group that offers a nicer syntax for configuring k8s labels and taints compared to bare ASGs) with a launch template that sets the image_id as:
"resolve:ssm:/aws/service/eks/optimized-ami/${local.cluster_version}/amazon-linux-2023/x86_64/standard/recommended/image_id"
This failed with a 400 error:
InvalidParameterException: Amazon EKS managed node group launch templates cannot contain a dynamically-resolved ImageId
Is there any workaround?
-
The AWS roadmap has a proposal to remove this limitation.benjimin– benjimin2025年11月26日 23:20:15 +00:00Commented Nov 26, 2025 at 23:20