Docker Compose: volumes without colon (:) -


i have docker-compose.yml file following:

volumes:   - .:/usr/app/   - /usr/app/node_modules 

first option maps current host directory /usr/app, second option do?

the second 1 creates anonymous volume. listed in docker volume ls long unique id rather name. docker-compose able reuse if update image, it's easy lose track of volume belongs names, recommend giving volume name.


Comments

Popular posts from this blog

javascript - WinJS appendTextAsync producing scheduler errors -

minify - Minimizing css files -

Sockets with kotlin -