This codebase will deploy my resume to an s3 bucket hosted by Cloudfront. The website will have a visitor counter which will communicate with a DynamoDB Database to keep track of the visitor number. All of this will be deployed via a webhook and automated.
- Set up Route53 to point to CloudFront
-
Create Infrastructure
- DynamoDB
- S3 Bucket
- CloudFront
- Lambda
- Read the current number, increment it by 1, write new number to dynamo, return number to webpage
- No tests included as there is no input to lambda, all the code relies on itself. Running the code proves the tests.
- IAM Policies for everything
- API Gateway
-
Create Website (HTML, CSS, Javascript)
- HTML & CSS Resume
- Javscript Counter
- Should call API Gateway to get
- zip lambda code (if any changes were made)
- Deploy frontend-infrastructure
- upload lambda code to s3 bucket
- deploy backend infrastructure
- Update API url in the Javascript for the front-end
- Upload all website data to s3 bucket
- Invalidate CloudFront to pull new files from s3 bucket
- Profit
- There is a bug deploying the API Gateway. The lambda arn that is passed to it doesn't set correctly. If I go in an manually remove then add it again the API starts working.