Skip to main content

A tool for deploying Python projects to AWS Lambda.

Project description

A tool for deploying Python projects to AWS Lambda.

Usage

Usage: awslambda [OPTIONS] SOURCE_DIR S3_BUCKET

  Deploy Python code to AWS lambda.

  Zips the contents of the source directory together with optional pip
  requirements. The archive is temporarily uploaded to an S3 bucket and used
  to create or update lambda functions.

  Reference handlers from your source directory like you would in any Python
  module-tree (e.g. mymodule.myhandler, mymodule.mysubmodule.myhandler,
  etc.).

  Roles are ARNs like "arn:aws:iam::xxxxxxxxxxxx:role/myrole"

  YAML file entries for the sync option map function names to handlers and
  roles:

      myLambda:
          handler: mymodule.myhandler
          role: arn:aws:iam::xxxxxxxxxxxx:role/myrole

Options:
  -r, --requirements PATH         pip compatible requirements file. Will be
                                  included in the archive.
  -c, --create NAME HANDLER ROLE  Create a new lambda function. Example:
                                  --create myLambda mymodule.myhandler myrole
  -u, --update NAME               Update a lambda function.
  -d, --delete NAME               Delete a lambda function.
  -s, --sync FILENAME             Keep lambdas defined in YAML file in sync
                                  with deployed lambdas.
  --help                          Show this message and exit.

Getting started

Authentication is left to boto3 so you can set it up just like the regular AWS CLI. You need an S3 bucket for temporary storage. For a quick tutorial on execution roles, see the official docs .

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

awslambda-1.0.5.tar.gz (5.0 kB view hashes)

Uploaded Source

Built Distribution

awslambda-1.0.5-py2-none-any.whl (7.5 kB view hashes)

Uploaded Python 2

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