Skip to main content
Join the official Python Developers Survey 2018 and win valuable prizes: Start the survey!

Create AWS Lambda packages

Project description

Creates Python 2.7 packages for AWS Lambda, installing requirements and setting build-time variables.

Bare minimum

Lambpack’s purposely minimal - it only packages functions. No uploading, no publishing, no aspirations to become a framework.

Command-line example

Given a directory my-function containing:

Run the following to get packaged.zip, ready for upload to AWS Lambda:

$ pip install lambpack
$ lambpack my-function packaged.zip index.handler --env DEBUG=yes --env MY_OTHER_FLAG=123

Your function can access the --env variables via os.environ.

API example

As above, but via the API:

import lambpack

lambpack.to_zip(
    path="my-function",
    dest="packaged.zip",
    handler="index.handler",
    env={
        "ENV": "prod"
    }
)

See src/lambpack/packager.py for more info.

Project details


Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
lambpack-0.1.1.tar.gz (4.6 kB) Copy SHA256 hash SHA256 Source None Nov 4, 2016

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page