Skip to content

About

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

dinoleung.com

Personal site for myself, built as a small production-style static web app rather than a template portfolio.

The site is intentionally simple on the surface, but the repo shows how I tend to work: reproducible local tooling, explicit build commands, infrastructure as code, private-by-default hosting, and a bias toward maintainable systems over one-off setup.

What to Look At

For recruiters or engineering hiring managers reviewing this repo, the useful signals are:

  • Platform engineering habits: the site is deployed through AWS infrastructure described in OpenTofu, not configured manually through the console.
  • Reproducible development: the Nix flake pins the local toolchain used for Go, TinyGo, OpenTofu, AWS CLI, and task execution.
  • Simple operational model: the application builds to static assets and is served from private S3 through CloudFront.
  • Security-aware defaults: S3 public access is blocked, CloudFront uses Origin Access Control, response security headers are configured, and deploy permissions are scoped.
  • Clear delivery workflow: just tasks document the expected build, test, static generation, infrastructure, and deploy paths.

Tech Stack

  • Application: Go, go-app, WebAssembly
  • Build/runtime shape: static assets generated into dist/
  • Local tooling: Nix, direnv, Just, watchexec
  • Infrastructure: OpenTofu, AWS S3, CloudFront, ACM, Route 53, IAM
  • Deploy path: static sync to S3 plus CloudFront invalidation

Repository Layout

.
├── src/                 # Go app, routes, metadata, local server, static generation
├── web/                 # CSS, icons, manifest, generated WASM runtime assets
├── tools/socialgen/     # Social preview image generation
├── infra/opentofu/      # AWS hosting infrastructure
├── flake.nix            # Reproducible development shell
├── justfile             # Build, check, serve, infra, and deploy commands
└── README.md

Local Development

Enter the pinned development environment:

direnv allow

Install or tidy Go modules:

just mod

Run the site locally:

just serve

Open http://localhost:8080.

For rebuild-on-change development:

just watch

Build and Check

Build the WebAssembly app into web/:

just wasm

Generate the static site into dist/ and run tests:

just check

just check is the main pre-deploy verification command. It generates static assets, then runs:

go test ./...

Infrastructure

The AWS stack lives in infra/opentofu.

It provisions:

  • Private S3 bucket for static site assets
  • S3 ownership controls, versioning, encryption, lifecycle rules, and public-access blocks
  • CloudFront distribution with Origin Access Control
  • Cache policy and response security headers
  • Optional ACM certificate and Route 53 alias records
  • Scoped deploy IAM policy
  • GitHub Actions OIDC deploy role

Common commands:

just infra-init
just infra-plan
just infra-apply

See infra/opentofu/README.md for stack-specific setup notes.

Deployment

Deployment is intentionally boring:

just deploy

That command:

  1. Runs just check
  2. Syncs dist/ to the provisioned S3 bucket
  3. Creates a CloudFront invalidation

The bucket is not public. Public traffic is served through CloudFront.

Design Notes

The app is written in Go and compiled to WebAssembly with go-app. That is not the simplest way to build a personal landing page, but it keeps the project aligned with the kind of systems work I care about: explicit build steps, a small runtime surface, reproducibility, and deployable artifacts that can be reasoned about.

The frontend is deliberately compact. Most of the engineering value in this repo is in the end-to-end delivery path: local environment, build, static generation, infrastructure, permissions, and deployment.

About

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages