keithrozario/Klayers

Python Packages as AWS Lambda Layers

What it solves

AWS Lambda functions often require external Python libraries that aren't included in the standard runtime. Manually packaging these dependencies can be tedious and error-prone. This project provides a pre-built, ready-to-use collection of popular Python packages as AWS Lambda Layers, allowing you to add them to your functions without manual bundling.

How it works

The project maintains a library of Python packages built specifically for AWS Lambda. You can integrate these layers into your infrastructure using the AWS Console, the Serverless Framework, AWS SAM, Terraform, or AWS CDK. The project also provides an API that allows your infrastructure-as-code tools to automatically fetch the latest version of a package, ensuring your functions stay up-to-date.

Who it’s for

This is for developers and DevOps engineers working with AWS Lambda who want to simplify dependency management, reduce deployment package sizes, and avoid the overhead of manually creating and maintaining Lambda Layers for common Python libraries.

Highlights

  • Supports multiple Python versions and architectures (x86_64 and arm64).
  • Integrates seamlessly with major deployment tools like Terraform, CDK, and Serverless Framework.
  • Provides an API to programmatically retrieve the latest layer versions for specific regions.
  • Automatically builds and updates layers on the first day of every month.
  • Offers a clear lifecycle policy, with layers remaining available for at least 365 days after a new version is published.

Related

  • Project
  • Project
  • Project
  • Project