I\'m using docker-toolbox on windows home. I was able to run a jekyll-serve web server image to see the default page on browser, but when I try to edit file on VS Code, I can no
Bind mounting actually does not work for docker toolbox:
file change events in mounted folders of host are not propagated to container by Docker for Windows
This script is intended to be the answer to this issue: docker-windows-volume-watcher.
This is a common issue with data manipulated outside of your container.
For jekyll, in particular, even the solution described in the issue below does not work for windows-based systems.
https://github.com/jekyll/jekyll-watch/issues/17
In short you need to execute jekyll with the --force_polling
flag (Does not work with Windows Hosts). You can find it in the jekyll docs here
https://jekyllrb.com/docs/configuration/options/
On Linux based systems it works out of the box since the image used in the question bretfisher/jekyll-serve
already utilizes the --force_polling
flag.
just ran
docker run --rm -it -e JEKYLL_NEW=true -p 8080:4000 -v (pwd):/site bretfisher/jekyll new .
to create a new jekyll site and
docker run --rm -it -e JEKYLL_NEW=true -p 8080:4000 -v (pwd):/site bretfisher/jekyll-serve
to run it mounted to a directory on my machine (linux) and was able to edit a file with changes propagating to jekyll.