Example on how to run locally an AWS Lambda via API Gateway using localstack.
Based on...
- https://stackoverflow.com/questions/44547574/create-api-gateway-in-localstack/48682628
- https://ig.nore.me/2016/03/setting-up-lambda-and-a-gateway-through-the-cli/
- Build a zip containing
lambda.js
, name itapi-handler.zip
- Launch localstack in whatever way you can. See sample
docker-compose.yml
. - Run
setup.sh
Catch any URL./api/whatever
- Pass all HTTP verbs. Only
GET
is configured here. Other verbs require their own integration asANY
is not supported yet. - No query parameters yet.