Can a single EBS be shared across multiple Amazon Docker Containers?

I want to copy some data from S3 to EBS when the FIRST Docker Container spins off. For subsequent spawned Docker Containers, I want to share the data I copied on the EBS. I do not want data to be duplicated for every Docker Container.

Can anyone tell me if a single EBS can be shared across multiple Amazon Docker Containers ?

  • Dockerfile Script for Amazon AWS
  • Docker - unable to link container
  • Setting up credentials for docker and AWS windows
  • AWS when we have to update task definition
  • What will happen after the maximum number of images pushed to ECR repository
  • Persistent mysql data from docker container
  • Vagrant Error in Centos
  • DOCKER_OPTS are reset after system reboot
  • What is a Docker tag (looking for a definition)?
  • Docker Service updatedAt timestamp
  • Docker compose and volumes with Apache
  • ERROR: Service 'redis' failed to build. When building redis image by docker-compose
  • 2 Solutions collect form web for “Can a single EBS be shared across multiple Amazon Docker Containers?”

    Yes, multiple docker containers can share data located on an EBS volume attached to an EC2 instance if they are running on that EC2 instance.

    This is not possible with ECS as several EC2 instances would be involved.

    EBS can only be linked to a single ec2 instance

    • if you have docker containers spinned on single ec2 instance, it will work
    • If you have docker containers spinned on a ec2 cluster with multiple ec2 instances, it will not work; an option in such case would be to use EFS
    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.