DEV Community

Austin
Austin

Posted on

Deploying My Portfolio Website on AWS: A Cloud Engineer's Journey

As someone transitioning from technical support to cloud engineering, I wanted to create a portfolio website to showcase my work. While I’m not the biggest fan of front-end development, I was excited to get something live and demonstrate my cloud skills. So, I decided to build my site using simple HTML and CSS, host it on AWS, and use Terraform for infrastructure as code.

I’ve had some experience using the AWS console, but this was my first time working with Terraform. At first, I was a bit intimidated, but it turned out to be a fun challenge and a great learning experience. The goal was to automate the deployment of my portfolio website using AWS S3, CloudFront, and Route 53.

Initial Struggles with Terraform and CloudFront

The first obstacle came when I mistakenly passed in the AWS S3 bucket name instead of the S3 bucket endpoint in my CloudFront distribution. This caused some issues, but after tweaking my Terraform code, I was able to get that sorted out.

Next, I encountered a frustrating 403 error when trying to access my site. This is where I got hands-on with the dig tool, which helped me confirm that my website was pointing to CloudFront as intended. I was on the right track, but something still wasn’t right.

The SSL Handshake Error

After more troubleshooting, I decided to use curl to inspect the SSL certificate. That’s when I discovered there was an error with the SSL handshake. Further research led me to the solution: I needed to configure aliases for my domain in the CloudFront distribution.

The Final Fix

With that change in place, I re-ran my Terraform code and watched as everything fell into place. My website was finally live, with the proper SSL certificate and everything working smoothly.

While it took some time to troubleshoot, this project taught me a lot about Terraform, AWS, and the importance of paying attention to details like CloudFront configurations and SSL certificates. It was a rewarding experience, and I’m excited to continue exploring cloud engineering!

Top comments (0)