Skip to content
This repository has been archived by the owner on Aug 30, 2021. It is now read-only.

Live Reload Development and deployment With Docker #1110

Open
5un opened this issue Dec 19, 2015 · 0 comments
Open

Live Reload Development and deployment With Docker #1110

5un opened this issue Dec 19, 2015 · 0 comments

Comments

@5un
Copy link

5un commented Dec 19, 2015

Hello, I'm not sure if the current docker run command with live reload inside README.md reflects the current structure and configurations of the project.

The current:

docker run -p 3000:3000 -p 35729:35729 -v /Users/mdl/workspace/mean-stack/mean/public:/home/mean/public -v /Users/mdl/workspace/mean-stack/mean/app:/home/mean/app --link db:db_1 mean
  • Does mean/app needs to be mean/modules ?
  • I cannot get the container running properly by mounting both the /public and the /modules folder. On OSX (El Capitan), The container can start and go through all the grunt build processes and did start the web app at port 3000. But accessing the docker VM's address at port 80 in a browser shows a blank page. Turns out that javascript console says angular is undefined and my /public folder stays empty in my host file system. This is because the bower dependencies are installed into public/lib during Docker build in which the volume has not been mounted. So public directory will be empty be the time the container is running.
  • I can get it working if I mount just the /modules directory, for example
docker run -p 3000:3000 -p 35729:35729 -v /Users/mdl/workspace/mean-stack/mean/modules:/home/mean/modules --link db:db_1 mean

Is there any necessities for /public to be mounted as a volume? I think it's totally fine for the container to write into its own /public and I need to rebuild container if my non-build public files need update (for example public/robot.txt)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants