Stop writing your own scripts and let this package your python aws lambda zips for you
Project description
lambda-packager
Currently, requires python >=3.8 and later due to required features of copytree
##Usage
- You can run with the following:
$ lambda-packager
# or if not in the project directory
$ lambda-packager --project-directory path/to/project/dir
- lambda-packager will include any dependencies defined in
- poetry (pyproject.toml)
- requirements.txt
Pipenv(Coming soon!)
- By default lambda-packager will include all src files that match
*.py
- You can customise this through config in
pyproject.toml
:
[tool.lambda-packager]
src_patterns = ["lambda_packager/*.py"]
Hidden files
- Hidden files and folders are ignored by default when including src files
- if you wish to disable this, then add the following config to your
pyproject.toml
[tool.lambda-packager]
ignore_hidden_files = false
Ignore folders
If there are folders that you wish always exclude, then you can use ignore_folders
Note: ignore_folders
is always respected even if there was a match via src_patterns
[tool.lambda-packager]
ignore_folders = ["venv"]
Full usage
usage: lambda-packager [-h] [--project-directory PROJECT_DIRECTORY] [-l {DEBUG,INFO,WARNING,ERROR}]
Build code and dependencies into zip files that can be uploaded and run in AWS Lambda
optional arguments:
-h, --help show this help message and exit
--project-directory PROJECT_DIRECTORY
The path to the top level project directory. This is where source files and files that declare dependencies are expected to be held. Defaults to current directory
-l {DEBUG,INFO,WARNING,ERROR}, --log-level {DEBUG,INFO,WARNING,ERROR}
set output verbosity, defaults to 'INFO'
License
This code is open source software licensed under the Apache 2.0 License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
lambda-packager-1.1.0.tar.gz
(9.9 kB
view hashes)
Built Distribution
Close
Hashes for lambda_packager-1.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ebb03f3dc7796e0ef24d2de86b3d16cc1d109a912dcb2fbee3a5d7726b0c22f2 |
|
MD5 | d4c47cadf4fab0c8d116d9d28bc97826 |
|
BLAKE2b-256 | c73b25d448f8210946c8f132a1dcab2db0c886532cd565846fdaaf4eacc74f00 |