title: Error using EFS in ECS, returns unknown filesystem type 'efs'
body: <p>I'm using a docker image for jenkins (jenkins/jenkins:2.277.1-lts-alpine) in an AWS ECS, and I want to persist the data using a AWS EFS.
  I created the EFS and got the ID (fs-7dcef848)</p>
  <p>My terraform code looks like:</p>
  <pre><code>resource &quot;aws_ecs_service&quot; &quot;jenkinsService&quot; {
      cluster = var.ECS_cluster
      name = var.jenkins_name
      task_definition = aws_ecs_task_definition.jenkinsService.arn
      deployment_maximum_percent = &quot;200&quot;
      deployment_minimum_healthy_percent = 50
      desired_count = var.service_desired_count
      tags = {
        &quot;ManagedBy&quot; : &quot;Terraform&quot;
      }
  }
  
  resource &quot;aws_ecs_task_definition&quot; &quot;jenkinsService&quot; {
    family = &quot;${var.jenkins_name}-task&quot;
    container_definitions = file(&quot;task-definitions/service.json&quot;)
    volume {
      name  = var.EFS_name
      efs_volume_configuration {
        file_system_id = &quot;fs-7dcef848&quot;
      }
    }
    tags = {
        &quot;ManagedBy&quot; : &quot;Terraform&quot;
    }
  }
  </code></pre>
  <p>and the service.json</p>
  <pre><code>[
    {
      &quot;name&quot;: &quot;DevOps-jenkins&quot;,
      &quot;image&quot;: &quot;jenkins/jenkins:2.284-alpine&quot;,
      &quot;cpu&quot;: 0,
      &quot;memoryReservation&quot;: 1024,
      &quot;essential&quot;: true,
      &quot;portMappings&quot;: [
        {
          &quot;containerPort&quot; : 8080,
          &quot;hostPort&quot; : 80
        }
      ],
      &quot;mountPoints&quot;: [
        {
            &quot;sourceVolume&quot; : &quot;DevOps-Jenkins&quot;,
            &quot;containerPath&quot; : &quot;/var/jenkins_home&quot;
        }
        ]
    }
  ]
  </code></pre>
  <p>The terraform apply works OK, but the task cannot start returning:</p>
  <p><strong>Stopped reason</strong> Error response from daemon: create ecs-DevOps-jenkins-task-33-DevOps-Jekins-bcb381cd9dd0f7ae2700: VolumeDriver.Create: mounting volume failed: mount: unknown filesystem type 'efs'</p>
  <ul>
  <li>Does anyone know whats happening?</li>
  <li>There is another way to persist data?</li>
  </ul>
  <p>Thanks in advance.</p>