blocker icon indicating copy to clipboard operation
blocker copied to clipboard

implement volume tag detection to support services in Swarm mode

Open chanwit opened this issue 9 years ago • 0 comments

This PR implements tag detection in an EBS volume in a form of service=<name>. If matches, it will retrieve the volume id for the plugin to mount. With this PR, we are allowed to provision something like a stateful MySQL Galera cluster with a Docker service.

Example use case:

  1. Tag a volume with "service=myservice".
  2. Run the following command.
sudo docker service create --name test \
 --log-driver=journald \
  --mount "type=volume,volume-driver=blocker,src=db,target=/root,volume-opt=service=myservice" \
  alpine top

Signed-off-by: Chanwit Kaewkasi [email protected]

chanwit avatar Dec 16 '16 13:12 chanwit