Precision in the Cloud: How I Built a Serverless Portfolio from the Ground Up
Coming from a background as a Medical Doctor, my career has always been about systems—diagnosing failures, understanding anatomy, and following rigorous protocols. As I pivoted into Cloud Engineering, I realized that a healthy cloud architecture is a lot like a healthy patient: it requires monitoring, scalability, and high-stakes troubleshooting.
The Anatomy of the Project
I didn't just build a website; I built a distributed system. The stack is entirely serverless, ensuring that I only pay for what I use while maintaining the ability to scale to thousands of visitors instantly.
- The Frontend: Hosted on Amazon S3 and delivered globally via Amazon CloudFront. I used Route 53 for DNS and AWS Certificate Manager for HTTPS encryption.
- The API: A "heartbeat" for the site. A JavaScript fetch call triggers an API Gateway endpoint.
- The Logic: An AWS Lambda function written in
Pythonhandles the backend, usingBoto3to communicate with the database. - The Persistence: Amazon DynamoDB stores visitor counts, utilizing atomic updates to ensure data integrity.
Reliability Through Automation (CI/CD)
In medicine, you don't perform a procedure without a checklist. In DevOps, you don't ship code without a pipeline. I built two GitHub Actions workflows:
1. Backend: Every push triggers a suite of unit tests using Pytest and Moto. Only passing tests trigger a SAM deployment.
2. Frontend: Updates are synced to S3, followed by a CloudFront cache invalidation to ensure immediate global updates.
Closing Thoughts
This challenge was a bridge between my past in healthcare and my future in technology. It taught me that whether you are diagnosing a patient or a latent API bottleneck, the principles of systematic troubleshooting remain the same.