I'm trying to setup an NPM Package Feed on Azure DevOps Server 2020, and am running into an issue with installing/adding packages to that feed.
I have the feed set as my registry in my .npmrc
, and am able to install packages from the feed, however, I am unable to publish some packages. The reason for having to publish the packages in this manner is that the server that the packages are being installed to/stored on (when running npm install
) is unable to connect to the public npm registry. The server has very strict egress filtering due to security, so this will most likely not be able to be changed.
To get around this, I am manually installing a package that I want to publish (webpack for example), publishing it to the package feed, and then also publishing all of its dependencies in the node_modules
folder. However, some dependencies run into errors when trying to publish them (acorn is one package that's being problematic).
Since the build server is unable to egress to the public registry, is there a better way to publish all of a package's dependencies to the package feed? If there isn't a better way, should I be installing each dependency before publishing it? Again, the server that is actually installing/hosting the packages in the feed has network egress disabled, and is unable to connect to the public npm registry, so all packages must be installed to my local computer, and then published to the feed.