Skip to content

aws-samples/aws-lambda-layer-builder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

AWS Lambda Layer Builder

If you've ever needed to build a Lambda layer quickly and easily, this tool is for you.

Prerequisites

Installation

Copy the make-layer file to a location on your path, e.g. cp make-layer /usr/local/bin/.

Download and install with a single command by copying and pasting the following into a terminal:

INSTALL_LOC=/usr/local/bin/make-layer; curl https://raw.githubusercontent.com/aws-samples/aws-lambda-layer-builder/main/make-layer > $INSTALL_LOC; chmod +x $INSTALL_LOC

Usage

This tool can either take a list of packages to include in the layer, or a package manifest file valid for the specified runtime. It assumes the AWS CLI is already properly configured.

Run make-layer without parameters for full usage instructions.

Manifest File

make-layer NAME RUNTIME MANIFEST
  • NAME is a valid Lambda layer name (letters, numbers, hyphens, and underscores)
  • RUNTIME is a valid Lambda runtime identifier (e.g. nodejs14.x, python3.8)
  • MANIFEST is the full path and filename of a valid manifest file. The following types are supported:

If the manifest file is not found the parameters are presumed to be explicit package names.

Explicit List

make-layer NAME RUNTIME PACKAGE_1 [PACKAGE_2] ...
  • PACKAGE_1, PACKAGE_2, etc. are the packages to be installed.

To-Do

  • Add parameter for AWS profile to use (currently uses default, or honors AWS_PROFILE)
  • Add support for additional runtimes

Contributing

Pull requests are welcomed. Please review the Contributing Guidelines and the Code of Conduct.

Security

See CONTRIBUTING for more information.

Authors

License

This project is licensed under the MIT-0 License. See the LICENSE file for details.

About

Script for quickly creating AWS Lambda Layers

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages