package fails for private npm modules

Đang mở
#415 2 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
45/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
javascript, nodejs
Lĩnh vực
cli

Hướng nghiên cứu

Start at the node-lambda package command and trace how it launches the container and runs npm install --production. Determine how the NPM_TOKEN environment variable can reach that process, then verify that packaging succeeds for a package.json containing private npm modules.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

enhancement question

Packaging with:

node-lambda package ...

will fail when package.json contains modules that are private on npm. I found a solution was to make a .npmrc file, put the following contents in it, and .gitignore it.

//registry.npmjs.org/:_authToken=00000000-0000-0000-0000-000000000000

However, as suggested on the npm docs, they recommend exporting an environment variable instead from your ~/.profile, or ~/.bashrc...

export NPM_TOKEN="00000000-0000-0000-0000-000000000000"

Then, use a NPM_TOKEN environment variable inside the .npmrc:

//registry.npmjs.org/:_authToken=${NPM_TOKEN}

How does one pass the NPM_TOKEN environment variable into the node-lambda package container so that it can be available when it executes npm install --production?

Ngôn ngữ chính
JavaScript
Star
1.4k
Fork
185
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của motdotla/node-lambda

Tất cả issue của motdotla/node-lambda

Issue tương tự

Thêm issue về JavaScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.