DEV Community

loading...

Discussion on: The beauty of Docker for local Laravel development

Collapse
aschmelyun profile image
Andrew Schmelyun Author

Hey Tim!

So essentially when it says "Store your files in the WSL file system" it means in the Linux partition that Windows creates when using WSL.

If you open up a Windows Terminal session in Bash, by default it should put you in a directory called like /mnt/c/Windows. Run cd ~ to get to the home directory in the WSL file system, and then from there you can use any directory under that one to create your Docker-ized application and it will run way faster.

For instance, I have mine at ~/Sites/example.com. Let me know if that helps!

Collapse
tkoop profile image
Tim Koop • Edited

So in your docker-compose.yml file, what do your volumes look like? I changed mine from
volumes:
- .src:/var/www/html
to
volumes:
- ~/site:/var/www/html
And now I get a 404 error, even thought there is an index.html file there.

Thread Thread
tkoop profile image
Tim Koop

To answer my own question, the answer is to run docker-compose inside wsl, not from the Windows prompt.