node.js - docker's VOLUME isn't mounting host files -
i have docker file:
from node:0.10.38 volume /opt/build workdir /opt/build expose 8080 cmd node app.js however, when got run container, error app.js not exist, /opt/build/app.js not exist. i've tried add , copy this, both can't find anything, , i'd use volume writes host's log in /opt/build. desired files in fact on host well. way, i'm using coreos host os.
as documented in http://docs.docker.com/userguide/dockervolumes/#volume --
the volume dockerfile command equivalent -v /opt/build ("adding data volume"), not equivalent -v /opt/build:/opt/build ("mount host directory data volume"); latter want here.
Comments
Post a Comment