Posted On: Dec 1, 2020
You can now package and deploy AWS Lambda functions as a container image of up to 10 GB. This makes it easy to build Lambda based applications using familiar container tooling, workflows, and dependencies. Just like functions packaged as ZIP archives, functions deployed as container images will benefit from AWS Lambda’s operational simplicity, automatic scaling with sub-second startup times, high availability, and native integrations with 140 AWS services. Customers can start building functions as container images by using either a set of AWS base images for Lambda, or by using one of their preferred community or enterprise images.
You can use familiar container development tools such as Docker CLI to locally build and test your Lambda based application, and push your container image to Amazon ECR - a fully-managed container registry. You can then deploy your Lambda function by specifying your Amazon ECR image tag or digest from the repository.
With this launch, AWS provides a set of base images for Lambda that are available on ECR Public and Docker Hub. You can also build and deploy your function using your preferred base images. We have open-sourced a set of software packages, Runtime Interface Clients (RIC), that implement the Lambda Runtime API, allowing you to seamlessly extend your preferred base images to be Lambda compatible. The Lambda Runtime Interface Clients are available for popular programming language runtimes. To make it easy to locally test Lambda functions packaged as container images we open-sourced a lightweight web-server, Lambda Runtime Interface Emulator (RIE), which allows your function packaged as a container image to accept HTTP requests. This allows you to use familiar tools like cURL to test invokes on a locally running container image. RIE is included in the AWS Lambda provided base images, and is open sourced on GitHub for use with your preferred images.
To learn more, visit AWS Lambda documentation. You can use this feature with AWS CloudFormation, AWS SAM, and IDEs such as the AWS Toolkits for Visual Studio, VS Code, and JetBrains. You can use existing serverless tooling and Lambda features for functions packaged as container images.
Container image support for Lambda is generally available, and you can use it in the following AWS Regions: US East (Virginia), EU West (Ireland), APAC NE (Tokyo), US West (Oregon), APAC SE (Singapore), EU Central (Frankfurt), US East (Ohio), and SA East (Sao Paulo). We are working to add support in more AWS regions soon.