Backend for my portfolio site on damonwilliams.co.uk
- PHP: I've been using PHP since 2006, so I know it pretty well.
- Serverless Framework: Serverless Framework allows the API to run on AWS Lambda. This means it's now (almost) infinitely scalable, with consistent response times.
- NodeJS: Serverless runs on NodeJS, so is a required dependency
- DynamoDB: It's scalable for what I need (as in if it's not in use, it costs nothing), plus I can run triggers on the stream for when new data appears
- Bref.sh: PHP Layer for AWS Lambda allowing PHP to be run natively.
- PHPUnit: Unit testing, as that's pretty important.
- PHPCS: Code sniffer to make sure the code adheres to the PSR-12 standard
- PHPStan: Static Analysis to make help spot those pesky bugs earlier.
- iamlive: To record minimum IAM permissions required for deployment.
- Terraform: To create the role and deployment bucket ahead of time to allow the Lambda deployments to follow the Principle of least privilege
- Unfortunately, I couldn't see a way for DynamoDB / SES to handle transactions. This means if the email sends, but Dynamo fails to update the record, we may receive duplicate emails.