Nexus-compliant repository to get node and npm installers

自闭症网瘾萝莉.ら 提交于 2019-12-19 02:54:07

问题


I am looking for a nexus-compliant repository where I can get a node installer (a nexus-compliant alternative to http://nodejs.org/dist/.

Context :

In a java environment, our builds are processed by maven. Recently we add a javascript frontend app and I am trying to get it built via maven with the excellent plugin frontend-maven-plugin.

The plugin installs node and npm, then run npm install and grunt build. Everything works perfectly.

But we MUST put all our dependencies under nexus (or some locally proxified repository).

  • About frontend dependencies: no problem since nexus 2.10 supports the npm registries. It works.

  • About the node and npm installers, they are initially downloaded from http://nodejs.org/dist/ by the plugin, and I do not know how to locally proxify this repo ... or where I can find theses installers on a nexus-compliant's one.

Any suggestions ?

Thx.


回答1:


I would suggest to create a pull request/patch for the frontend plugin that allows you to add a full url for npm and node rather than just the version and the root url. Then you can host the two installed e.g. by uploading them to Nexus into a Maven 2 repository and using that URL. I filed an issue for that btw. https://github.com/eirslett/frontend-maven-plugin/issues/126

Alternatively could try to create a site repository in Nexus with the same structure and use that.



来源:https://stackoverflow.com/questions/27289651/nexus-compliant-repository-to-get-node-and-npm-installers

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!