You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
https://docs.aws.amazon.com/lambda/latest/dg/nodejs-package.html says "If your function depends only on standard libraries, or AWS SDK libraries, you don't need to include these libraries in your .zip file. These libraries are included with the supported Lambda runtime environments."
serverless-lift should not include aws-sdk as it bloats the resulting .zip. Should aws-sdk be as devDependency?
It's possible to exclude aws-sdk explicitly using package pattern, but it should be excluded by default.
The text was updated successfully, but these errors were encountered:
Lift uses the AWS SDK to make calls to the AWS API. For example to upload static website files, etc. So it's not really a dev dependency of Lift (i.e. it's not used by Lift's tests).
However, Lift should be installed as a dev dependency in your project. Indeed, your Lambda functions do not use Lift. Only your deployment (sls deploy).
If you install Lift as a dev dependency it shouldn't increase the size of what you deploy, right?
From the top of my head, I'd say we can't because Lift doesn't get executed in the Lambda environment but it's executed when running serverless deploy or serverless package so you need it locally.
If it was listed in devDependencies of Lift, I guess it would not get installed in your project and thus Lift would not work as expected.
But maybe you could install Lift as a dev dependency and serverless should exclude it when deploying IIRC
I wonder what installed serverless-lift in dependencies in the first place, but now as I tried from scratch - it's correctly in devDependencies. I'll close this issue, thanks for the info!
https://docs.aws.amazon.com/lambda/latest/dg/nodejs-package.html says "If your function depends only on standard libraries, or AWS SDK libraries, you don't need to include these libraries in your .zip file. These libraries are included with the supported Lambda runtime environments."
serverless-lift should not include aws-sdk as it bloats the resulting .zip. Should aws-sdk be as devDependency?
It's possible to exclude aws-sdk explicitly using package pattern, but it should be excluded by default.
The text was updated successfully, but these errors were encountered: