How I made this page (cheaper)
A while ago I wrote How I made this page: Hugo on AWS with S3, CloudFront, Lambda@Edge, Route 53, and ACM. It works great and costs a few dollars a month. If you want the same result for free and don’t need a custom domain, you can skip AWS and use GitHub Pages instead. If you do run it on a custom domain (CNAME to GitHub Pages), the only cost is Route 53 in AWS for DNS.
GitHub Pro + public Pages from private repos
With GitHub Pro (or Team/Enterprise), you can publish GitHub Pages from a private repository. The site is still public at https://<username>.github.io/<repo>/, but the source stays private. So you get a public blog without opening the repo.
If you’re on GitHub Free, you can do the same with a public repo; the workflow below is identical.
One workflow: build Hugo and deploy
No Terraform, no AWS credentials, no S3 or CloudFront. A single workflow:
- Checkout the repo (with submodules if you use a Hugo theme as a module).
- Setup Hugo (e.g.
peaceiris/actions-hugowith the extended version). - Build with
hugo --minify. For project sites you must set the base URL to your Pages URL, e.g.--baseURL "https://wozniakpl.github.io/bwozniak.com/", or assets and links will break. - Upload the
publicfolder as a Pages artifact (actions/upload-pages-artifact). - Deploy with
actions/deploy-pages.
In the repo: Settings → Pages → Build and deployment, set Source to GitHub Actions. After each push to main, the workflow builds Hugo and deploys; the site updates in a minute or two.
What you’re not paying for
- No S3, CloudFront, Lambda@Edge, Route 53, or ACM.
- No IAM users or access keys to store in GitHub.
- No Terraform to maintain.
You’re just building a static site and letting GitHub host it. If you’re already on GitHub Pro (or fine with a public repo), this is the cheapest way to run a Hugo blog.