This project is an example of using AWS serverless infrastructure to create a three tier application. It uses DynamoDB as it’s backend store, lambda as the mechanism of pulling data from a 3rd party API and then exposed via an API gateway.
There is also an S3 bucket hosting a static webpage that consumes the lambda api, and that can be found here: https://richards-lambda-test-qa.s3.eu-west-2.amazonaws.com/index.html
To run this locally you will need Ruby 2.5.x and Terraform 0.11.x. I use asdf version manager for this. But you can use any version or package manager you prefer.
You will also need to install the AWS SAM cli
Run terraform apply -var-file="$HOME/.aws.tfvars"
to create the S3 buckets and DynamoDB table.
Then follow the deploy guide in the [Useful resources](# Useful resources)
- Remove remaining references to initial project idea (park-run)
- Work out how to inject secrets into the lambda
- Have diffent CORS policy for local and production enviorment
- Add DNS via Route 53
- Add Cloudfront distribution for the static site
- Redo and TDD the Ruby lambda