blocker
blocker copied to clipboard
implement volume tag detection to support services in Swarm mode
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:
- Tag a volume with "service=myservice".
- 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]