Sign inSign up

raphaelbh/lambda

By raphaelbh

•Updated over 3 years ago

Docker image for invoke lambda locally.

Image
0

323

raphaelbh/lambda repository overview

⁠Lambda

Project Status

Docker image used for invoke and update lambda functions locally.

Repository: https://github.com/raphaelbh/lambda-local⁠

Available actions:

  • invoke ${event}
  • update-code ${lambda-name}

update-code: update lambda code created in the localstack⁠

⁠Usage

A folder with the lambda function must be informed through a volume: {your_folder}:/lambda

Important:

  • /var/run/docker.sock should be shared as volume
  • Local network should be shared --net=host
# create alias for container run
alias lambda="docker run -v /var/run/docker.sock:/var/run/docker.sock -v $(pwd)/sample/lambda:/lambda --net=host raphaelbh/lambda"
# call invoke action
$ lambda invoke '{"key":"value"}'
or
$ lambda invoke $(cat sample/events/event.json | tr -d " \t\n\r")
# call update-code action
$ lambda update-code 'LambdaFunctionName'

⁠Feedback

If you have any feedback, please contact me at [email protected]⁠

github linkedin

Tag summary

Content type

Image

Digest

sha256:2d8eabc66…

Size

142.9 MB

Last updated

over 3 years ago

docker pull raphaelbh/lambda