apex / apex/up

Exclude dev dependencies from Node.js runtime package

Đang mở
#603 16 bình luận 2 reaction 0 người được giao Xem trên GitHub
Feature Request UX
Ngôn ngữ chính
Go
Star
8.8k
Fork
383
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

## Prerequisites

* [x] I am running the latest version. (`up upgrade`)
* [x] I searched to see if the issue already exists.
* [x] I inspected the verbose debug output with the `-v, --verbose` flag.
* [ ] Are you an Up Pro subscriber?

## Description

I am getting `Error: building: building: zip contents is 269 MB, exceeding Lambda's limit of 262 MB
` because my devDependencies in node_modules (Node.js project) are included in a zip file. I have quite a lot of them so putting them manually to `.upignore` is not convenient. Would be nice if there was an option to automatically exclude devDependencies from Lambda zip package. I know that serverless.js does this automatically when building Lambda package(s).
For example here is a list of my dev dependencies:

```
"@babel/cli": "^7.0.0-beta.32",
"@babel/core": "^7.0.0-beta.32",
"@babel/node": "^7.0.0-beta.32",
"@babel/plugin-proposal-class-properties": "^7.0.0-beta.32",
"@babel/plugin-proposal-decorators": "^7.0.0-beta.32",
"@babel/plugin-proposal-export-namespace": "^7.0.0-beta.32",
"@babel/plugin-proposal-object-rest-spread": "^7.0.0-beta.32",
"@babel/plugin-transform-classes": "^7.0.0-beta.32",
"@babel/preset-env": "^7.0.0-beta.32",
"@babel/preset-flow": "^7.0.0-beta.32",
"@babel/register": "^7.0.0-beta.32",
"babel-eslint": "^8.0.2",
"babel-plugin-istanbul": "^4.1.5",
"babel-plugin-root-import": "^5.1.0",
"chai": "^4.1.2",
"cross-env": "^5.1.1",
"flow-bin": "^0.59.0",
"inquirer": "^5.1.0",
"mocha": "^4.0.1",
"nock": "^9.1.3",
"nyc": "^11.3.0",
"opn-cli": "^3.1.0",
"rimraf": "^2.6.2",
"sinon": "^4.1.2",
"standard": "^10.0.3",
"up": "^1.0.1"
```

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

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

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.