portfolio/README.md
Nik Afiq 1a2e56267d
All checks were successful
CI / build-check (push) Has been skipped
CI / build-and-push (push) Successful in 2m23s
Added README to the repository
2026-03-18 19:15:15 +09:00

2.8 KiB

nik4nao — Personal Portfolio

Personal portfolio site built with Hugo and the terminal theme. Deployed as a containerised nginx image to a self-hosted Kubernetes cluster via Gitea Actions.

Live at nik4nao.com


Structure

content/
  posts/          # Blog posts
  projects/       # Project showcase pages
  cv.md           # CV / resume page
layouts/
  cv/single.html          # CV page template with download link
  projects/list.html      # Projects index (card grid)
  projects/single.html    # Project detail page
  index.html              # Homepage
static/
  css/custom.css          # Style overrides
  cv/nik-afiq-cv.pdf      # CV PDF (place manually)
themes/terminal/          # Git submodule

Local development

Prerequisites: Hugo extended, Git

git clone --recurse-submodules <repo-url>
cd portfolio
hugo server -D

The site will be available at http://localhost:1313.


Adding content

Blog post

hugo new content posts/my-post.md

Project

Create content/projects/my-project.md with this front matter:

---
title: "Project Name"
description: "Short description shown on the projects index."
tags: ["go", "kubernetes", "docker"]
github: "https://github.com/nik/project"
url: "https://project.example.com"
---

Project body in Markdown...

No code changes required — the project will appear automatically on /projects.

CV

Edit content/cv.md directly. The PDF download link points to static/cv/nik-afiq-cv.pdf; replace that file to update the downloadable version.


Build

hugo --minify
# Output written to public/

Or via Docker:

docker build -t portfolio .
docker run -p 8080:80 portfolio

CI/CD

Gitea Actions pipeline at .gitea/workflows/ci.yaml.

Event Jobs
Push to main Build + push multiarch image (linux/amd64, linux/arm64), deploy to cluster
Pull request Hugo build check only — no push, no deploy

Images are tagged latest and <short-sha> and pushed to gitea.home.arpa/nik/portfolio.

Deployment rolls out deployment/portfolio in the portfolio namespace via SSH + kubectl.

Required secrets

Secret Purpose
CA_CERT Internal CA cert for the self-hosted registry
REGISTRY_USER Gitea container registry username
REGISTRY_PASSWORD Gitea container registry password
SSH_PRIVATE_KEY SSH key for deploy host (192.168.7.77)

Theme

panr/hugo-theme-terminal — added as a git submodule at themes/terminal. Do not modify theme files directly; all overrides live in layouts/ and static/css/custom.css.