There is a Vue project (let's call it X) that I forked (let's call it X2) to do some customizations. That project has a Dockerfile that I use to compile everything, build a Docker image and deploy it on a server. Works perfectly well with forked X2.
Now some of the functionality of X is outsourced into a Vue library (let's call it Y), which also needs to be compiled via npm run build. It's a npm package, so it's simply defined in the package.json.
Now I need to change some things in Y, so I forked it (Y2). Since the fork is no npm package, I cannot download it from there during the Docker build process. And I also cannot download it from the forked git repo, since the built dist files are not in there.
What would be the easiest way to include it in the Docker image? The only way I can think of is:
- In the
Dockerfilecopy the library into the image and compile it. - Remove Y from the
package.jsonof X2, copy X2 into the image andnpm installit. - Manually install Y2 via
npm install /path/to/Y. - Build X2.
Any easier way?