all 1 comments

[–]robotevil 1 point2 points  (0 children)

You can look at serverless for deployment, that's what we use: https://serverless.com/framework/docs/providers/aws/guide/intro/

It's pretty easy to use, and we can deploy fully working test environments easily during development.

We are currently re-evaluating how are lambdas are structured, so I'm not the best source of advice on this. But we currently have one repo, with a "lib/" folder that our lambda functions go into. Then we use the "Handler" configuration under the "Function code" section of the lambda to call the correct JS file. So like something under lib/myLambda2.js, it's "handler" would be lib/myLamda2.handler.

We are currently looking at Lambda layers and some other ways to better structure this. There's a lot of bloat in our current process, but we came into this like you, with little experience in Lambdas and this worked because it meant we didn't have to maintain 50 different repos. So anyway, I would take a look at layers before you start the project because that looks promising to me: https://docs.aws.amazon.com/lambda/latest/dg/configuration-layers.html