Skip to main content

A simple CLI for building and publishing AWS Lambda functions.

Project description

AWS Lambda CLI

A simple CLI (Command Line Interface) tool to interact with AWS Lambda functions and Lambda layers.

Installation

To get started, install the package:

pip install aws-lambda-cli

and run the help command:

lambda --help

See examples below for more details.

License note:

This project is licensed under GPL-3, whose license restrictions apply to the distribution (propagation) and modification of this project. Usage for personal/development purposes does not carry the same requirements (disclosure, same license, etc.), however, warranty and liability limitations are still in effect. See section 9 of the license for details.

TODO

  • Add layer support
  • Add mypy and flake/ruff
  • Unittests?
  • Build actions

Examples

  • Show CLI version
lambda -V
  • Use a cli profile called work, and act on the eu-central-1 region:
lambda --profile work --region eu-central-1 <subcommand>

Type lambda --help for more authentication options.

  • Configure default parameters (such as authentication) to be used with all the following commands: This saves the configuration to file in the user's home directory. See lambda config --help for more details.
lambda config set --profile work --region eu-central-1
lambda function Test main.py # Using profile work and region eu-central-1 
  • Build, upload, and publish main.py to the function Test:
lambda function Test main.py --publish
  • Use an S3 bucket called resources:
lambda function Test main.py --aws-s3-bucket resources
  • Upload a project folder:
lambda function Test src
  • Build locally, and keep the output file without uploading:
lambda function Test main.py --out out.zip --no-upload

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aws_lambda_cli-0.2.0.tar.gz (20.7 kB view hashes)

Uploaded Source

Built Distribution

aws_lambda_cli-0.2.0-py3-none-any.whl (24.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page