'terraform v0.11 - invalid or unknown key: efs_volume_configuration
just want to ask if you have any idea on whats missing here on the terraform code block:
resource "aws_ecs_task_definition" "task_definition" {
family = "${lower(var.MY_FAMILY_ID)}-${lower(var.TYPE)}}-efs"
network_mode = "awsvpc"
cpu = var.CPU
memory = var.MEMORY
requires_compatibilities = ["FARGATE"]
container_definitions = data.template_file.ecs_template.rendered
execution_role_arn = data.iam_role.ecs_role.arn
task_role_arn = data.iam_role.ecs_role.arn
volume {
name = "my-volume"
efs_volume_configuration {
file_system_id = data.aws_efs_file_system.efs.id
root_directory = "/pogi"
}
}
}
The Terraform code above is verified working on Terraform v0.14 however when trying to use on Terraform v0.11 it gives this message.
Error: aws_ecs_task_definition.ecs_task_definition: volume.0: invalid or unknown key: efs_volume_configuration
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
