Concurrent data access by multiple docker swarm containers


Is there a way to control concurrent access to shared data by multiple docker swarm containers of the same service? For example, if there are multiple files in a shared mounted path for all containers of the same service, and I want each container to access a file that is not already accessed by another container of the same service, does docker swarm (or docker in general) provide concurrency control (like locking or lock-free tools)?


no… docker does not provide any data synchronization capabilities… you application design must take that into account…