I use git submodules to make it easier to create a docker-compose file to work on my laptop.
I mount each submodule via volume.
As a result, each service is present at the top level .git file with a link to the parent repository.
One of the projects uses a private package distributed via npm. When trying to download the yarn package, it crashes with an error because it uses git and git cannot find the parent repository.
How can I fix this?
CodePudding user response:
You have to create a file .dockerignore
a put .git
inside it.