replicate-images is an AWS Lambda function for use with Lambder.
REQUIRES:
- python-lambder
-
Test the sample lambda function
python lambda/replicate-images/replicate-images.py
-
Deploy the sample Lambda function to AWS
lambder functions deploy
-
Invoke the sample Lambda function in AWS
lambder functions invoke --input input/ping.json
-
Add useful code to lambda/replicate-images/replicate-images.py
-
Add any permissions you need to access other AWS resources to iam/policy.json
-
Update your lambda and permissions policy in one go
lambder functions deploy
If you decide to share your lambder function, you want to be sure you don't share
the name of your s3 bucket. We suggest you add lambder.json
to your
.gitignore
so it won't be commited to your repo. Instead, copy it to
example_lambder.json
and remove any secrets before pushing to a public
repository.
Your Lambdas should be as small as possible to reduce spinup time. If you need to include extra python modules, use virtualenvwrapper. The deploy script will look for a site-packages directory in $WORKON_HOME/lambder-replicate-images and bundle those packages into the zip that it uploads to AWS Lambda.