I have the following setup
- jenkins runs in a docker container
- in a sibling docker container I run a private npm registry
- I use the Docker Pipeline Plugin and a Jenkinsfile to build a typescript library (with a node docker container)
- I want to publish that library to that private registry to be able to use it in other build jobs
The problem is, as the registry runs on a port on the host it can't be reached from the docker in docker container that the Build Script spawns to build the lib. I find no info about how I can do something like --net="host" (from docker run) inside the jenkinsfile. I guess that would work?!
Any idea how I can improve the setup to build via a node docker container but be able to publish to the registry?