How to use a private npm registry on Elastic Beanstalk?

前端 未结 6 1025

We have a nodejs project running on Amazon Elastic Beanstalk that uses private modules that we host using nodejitsu\'s private npm registry.

However getting access t

6条回答
  •  旧巷少年郎
    2020-12-05 18:54

    Using an .npmrc within the project also works. For example...

    .npmrc

    registry=https://npm.mydomain.com
    

    You may want to .gitignore this file if you include an _authToken line but make sure you don't .ebignore it so it's correctly bundled up with each deployment. After trying a few things unsuccessfully, I came across this post which made me realize specifying it locally in a project is possible.

提交回复
热议问题