MatchbookLab / local-persist

Create named local volumes that persist in the location(s) you want
MIT License
852 stars 123 forks source link

Add one file mount support #49

Closed kisdaniel closed 6 years ago

kisdaniel commented 7 years ago

I would like to mount only one file like this:

docker-compose.yml example:

version: '3'
services:
  nginx:
    image: nginx
    volumes:
       - nginx-configfile:/etc/nginx/nginx.conf
volumes:
  nginx-configfile:
    driver: local-persist
    driver_opts:
      mountpoint: /var/lib/docker-persistent-volume/nginx/config/nginx.conf
CWSpear commented 6 years ago

I don't think this works as a limitation of Docker.

CWSpear commented 6 years ago

See https://github.com/moby/moby/issues/30310