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 ?

  • Where to put ebextensions config in AWS Elastic Beanstalk Docker deploy with dockerrun source bundle?
  • How install the Amazon ECS Container Agent in Debian? (ecs-init)
  • Can't install awscli to docker VM
  • Configure Dockerfile to set AWS configurations
  • How to identify whether my container is running on AWS ECS or not?
  • AWS Cloudwatch logs with Docker Container - NoCredentialProviders: no valid providers in chain
  • Change the owner of a file in a running Docker container with an attached volume in Windows
  • gitlab-ci runner's Docker Executor | How can I see docker container where the build is going on?
  • docker is not VM , why container need base image OS ? [closed]
  • Docker-Tuleap-List all Tuleap database tables running in docker container
  • Accessing microservice inside Docker container?
  • rhel docker usage - start process at container start
  • 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.