Serverless Lambda Layers
1 min read
serverless, lambda
Written in 2019. Tools, APIs and prices may have changed since.
Lab note What I wrote down while learning this by building with it. Short by design; the code is in pfeilbr/serverless-lambda-layers-playground.
learn lambda layers with serverless framework
Running
see serverless.yml and index.js
layers are applied in order, meaning last layer in array is applied last and will overwrite any common files in other layers.
# install deps
npm i
# run via local packages sls
npm run sls -- deploy
# invoke and view logs
npm run sls -- invoke --function hello --log

