Hello,
I am using this module to create an EKS cluster. Everything works well, but when I add a remote_access
config, terraform apply
fails with the following error:
Error: creating EKS Node Group [REDACTED] InvalidParameterException: Remote access configuration cannot be specified with a launch template.
Any idea on what I’m doing wrong? Here is the code:
module "eks" {
source = "terraform-aws-modules/eks/aws"
version = "18.31"
cluster_name = "REDACTED"
cluster_version = "1.25"
vpc_id = module.vpc.vpc_id
subnet_ids = slice(module.vpc.private_subnets, 0, 2)
enable_irsa = true
eks_managed_node_groups = {
mygroup = {
instance_types = ["t3.large"]
create_security_group = false
enable_monitoring = false
min_size = 2
max_size = 2
desired_size = 2
remote_access = {
ec2_ssh_key = "mysshkeypair"
}
}
cloudwatch_log_group_retention_in_days = 3
cluster_enabled_log_types = []
}
Thanks for your help!