Soooo...I'm Trying This Again...This Time with Hugo + AWS Amplify
- 6 minutes read - 1213 wordsHi, my name is Samuel Tillman, but you can call me Sam. I’m an IT Professional currently working as a Staff Site Reliability Engineer for the National Basketball Association. I spend most of my days waist deep in AWS infrastructure, Terraform, and whatever else is needed to keep systems running. I’ve been doing this tech thing for a while, so you you’d think maintaining a blog would be easy.
It ain’t…
…not for me anyway.
The First Attempt or 2…
I’ve built multiple sites in the past, usually a static site, using S3 buckets for hosting, CloudFront distributions for CDN, Route 53 for DNS, ACM for the SSL cert. All deployed with Terraform via Github Actions, because I practice what I preach. No ClickOps!!
They usually worked great. The infrastructure was always solid, but I never got past 1 or 2 posts. Writing the posts was just painful.
Every time I wanted to publish something, I had to:
- Write the HTML (or mess with whatever static generator I was using at the time)
- Build the site locally
- Run
terraform applyor sync to S3 manually or use a very complicated pipeline - Wait for CloudFront cache invalidation
- Realize I had a typo
- Do it all again…and again
Man after a while I was neglecting the sites so much that I’d forget to pay my AWS bills. Those fancy IaC pipelines I wrote just sat there in GitHub collecting dust.
So What Changed?
I decided to try again, but this time I had to find a solution that focused on the writing instead of overdosing on the infrastructure.
My requirements were simple:
- Had to still run on AWS, because it’s my fave cloud and I’ll fight about it.
- Publishing posts needed to be easy.
- Had to be git-based, because I needed a reason to use the phrase GitOps.
- Needed to be free or close to it, because my kids take all my money.
The Stack
Here’s what I landed on:
Hugo - Static site generator. Write in Markdown, it spits out HTML. Fast, simple, lots of themes.
GitHub - Repo for the site. Nothing fancy…not even GitHub Actions
AWS Amplify Hosting - This was the key. Connect your repo, Amplify builds automatically and deploys on every push. No more S3 buckets to manage, no CloudFront configs, and no cache invalidations to think about.
The Setup
It took me a about an hour to complete from thought to working site, but if you follow this guide, it might take you like 30-45 minutes. I’m a Mac user, so these steps are for a Mac, but Hugo works on Windows too…if enough folks ask for a guide, I’ll write one up.
1. Install Hugo
brew install hugo
2. Create a GitHub repo
Go to GitHub, create a new repository. I named mine samueltillman.com. Don’t initialize it with a README - we’ll push to it in a minute.
3. Create the site and connect to GitHub
git clone https://github.com/YOUR_USERNAME/your-repo-name.git
cd your-repo-name
hugo new site . --force
The --force flag lets Hugo create the site in a non-empty directory (the cloned repo).
4. Add a theme. I used the Ananke Gohugo Theme.
git submodule add https://github.com/theNewDynamic/gohugo-theme-ananke.git themes/ananke
echo "theme = 'ananke'" >> hugo.toml
5. Create first post
hugo new content posts/my-first-post.md
Edit the file, set draft: false.
6. Test locally
hugo server
Open localhost:1313. If it looks good, you’re ready to push.
7. Push to GitHub
git add .
git commit -m "Initial Hugo site"
git push
8. Set up Amplify
This is where the GitOps (used it) magic happens. Amplify connects directly to your repo and automatically builds and deploys your site every time you push.
Connect your repo:
- Go to AWS Console → search “Amplify”
- Click Create new app
- Select GitHub as your source
- Authorize AWS to access your GitHub account
- Select your repository and branch (usually
main)
Configure build settings:
Amplify tries to auto-detect your framework, but for Hugo you may need to set it manually. Click Edit on the build settings and use this:
version: 1
frontend:
phases:
build:
commands:
- hugo --minify
artifacts:
baseDirectory: public
files:
- '**/*'
What this does:
hugo --minify- Builds your site and minifies the output for performancebaseDirectory: public- Tells Amplify where Hugo outputs the built sitefiles: '**/*'- Deploy everything in that directory
Deploy:
Click Save and deploy. Amplify will:
- Pull your code from GitHub
- Spin up a build container
- Run the Hugo build
- Deploy the output to a CDN
- Give you a URL like
https://main.abc123.amplifyapp.com
The first build takes a minute or two. After that, every git push triggers a new build automatically. That’s GitOps - your Git repo is the single source of truth, and the infrastructure responds to changes in it.
9. Custom domain (Route 53)
I already had my domain samueltillman.com hosted on Route 53, so connecting it was straightforward:
- In Amplify, go to Hosting → Domain management
- Click Add domain
- Select your domain from the dropdown (Amplify sees your Route 53 hosted zones)
- Configure subdomains - I set up both
samueltillman.comandwww.samueltillman.com - Amplify automatically creates the DNS records in Route 53 and provisions an SSL certificate
The SSL cert took a few minutes to validate, but once it did, the site was live on my custom domain with HTTPS. No manual certificate management, no CloudFront distribution setup. Amplify handles it all.
The Workflow Now
Here’s what writing a new post actually looks like:
1. Create a new post:
hugo new content posts/my-new-post.md
This creates a new markdown file with the front matter already set up (title, date, draft status).
2. Write:
Open the file in VS Code (or whatever editor you like as long as it’s VS Code…lol) and write in Markdown. No HTML, no fussing with templates. Just content.
3. Preview locally:
hugo server
Open localhost:1313 and see exactly how it’ll look. Hugo has live reload, so as you save changes, the browser updates automatically. Very dope.
4. Publish:
git add .
git commit -m "New post: my-new-post"
git push
That’s it. Amplify detects the push, runs the build, and deploys. Usually takes about 30 seconds. No manual S3 syncing, no cache invalidation, no terraform apply.
The mental shift:
With my old setup, publishing felt like a chore. Now it’s just writing and pushing. The headache is gone, which means I might actually keep this blog updated.
Cost?
Amplify Hosting has a generous free tier. For a personal blog with modest traffic, it’s essentially free. Way less mental overhead than managing the S3/CloudFront stack myself.
Was the Terraform Approach Wrong?
No. It’s a great learning exercise and gives you full control. If I was building something for work with specific compliance requirements or complex routing needs, I’d probably go that route.
But for my personal blog where the goal is to actually write? Amplify is the right tool for the job.
So What’s Next?
I’m planning to write about the Cloud, primarily AWS, DevOps, my SRE work, and the occasional career reflection or rant. If you’re on a similar path, stick around.
I’m a Staff Site Reliability Engineer and I get busy with AWS, GitHub, Terraform, and VS Code, among other things. If you’re feeling it, subscribe below. Want to connect? Find me on LinkedIn, GitHub, or X.