How to exclude some paths when installing a volume?

I would like to install everything inside my current directory except /node_modules and /client/bower_components . Currently, I have to manually set all the paths as follows:

 app: build: . ports: - "3000:3000" - "35729:35729" links: - mongo volumes: - client/app:/www/app/client/app - client/assets:/www/app/client/assets - client/components:/www/app/client/components - server:/www/app/server ... mongo: image: mongo ports: - "27017:27017" 

Somehow I can exclude some paths, for example !client/bower_components and !node_modules ?

+7
docker docker-compose
source share
1 answer

No, It is Immpossible.

I think that your only options are either to rebuild the application directory structure, or to do what you are doing now and include all the paths.

+2
source share

All Articles