You usually will use the container option in one of the following two cases:
- You need a function with a package size larger than 250MB unzipped (containers support 10GB)
- You are already using containers in other places and would like to use the same tools you are using for containers
In other cases I would just use the zip file approach.
It also comes down to how you want to manage language runtimes. In AWS Lambda, container image packaged functions are similar to Zip files, but the customer is responsible for more artifacts, including the runtime, in the container image. If you take advantage of container packaging, the shared responsibility model for Lambda shifts, with the customer now being responsible for managing from the base image up. Since container images contain language runtime libraries, using a container image to package Lambda functions prevents Lambda from automatically updating the language runtime.
Multi-region lambda deployment with code stored in S3 bucketAccepted AnswerMODERATORasked 2 years ago
Lambda error codeasked 2 years ago
How to deploy 4 lambdas in typescript using a code pipeline ?asked 7 months ago
Lambda+ALB vs Lambda+API GWAccepted Answerasked 8 months ago
change lambda to no longer use zip deployment packageasked 3 months ago
Python Fast Api deploy in AWS lambdaAccepted Answerasked 4 months ago
How to Use CodeBuild and CodeDeploy to Deploy Lambda to Different Environmentsasked 7 months ago
Using python-magic in a lambdaasked 2 months ago
Is there a way to recover the deleted lambda function?asked 3 months ago
when to use ECR in lambda ?asked 5 months ago