Platform & Infrastructure Active Ongoing platform lab

K3s & GitOps Homelab

Self-hosted K3s cluster managed declaratively through Argo CD app-of-apps, Traefik v3 ingress, cert-manager, Sealed Secrets, Prometheus/Grafana observability, and a WireGuard gateway.

Private operational repository · Architecture overview
  • K3s
  • Argo CD
  • Traefik v3
  • cert-manager
  • Prometheus
  • Grafana
  • InfluxDB
  • WireGuard
  • Sealed Secrets
Private GitOps Repobootstrap / apps /SealedSecretsK3S CLUSTER (PUBLIC VPS)Argo CDApp-of-Apps syncTraefik v3 + TLScert-manager / LEPlatform OpsSealedSecrets / UIObservability StackPrometheus · Alertmanager · GrafanaTelemetry & Web ServicesMosquitto WSS · Telegraf · InfluxDBWireGuard Gateway (UDP 443) <--> Home LAN (OpenWrt, NAS, IoT)
High-level logical layout: declarative GitOps delivery, TLS ingress, observability, and VPN-only home LAN access.

Overview

This homelab serves as my personal production-like environment for validating Kubernetes patterns, GitOps workflows, observability setups, and secure remote networking outside work. It grew out of a migration from Docker Swarm to K3s, mirroring the same operational discipline I value in enterprise platforms—scaled down to stay maintainable by one person.

The live GitOps repository is kept private so operational configuration stays separate from public code. Everything described here focuses on the architectural decisions and operating principles.

Architectural Decisions

  • Declarative GitOps with Argo CD (App-of-Apps): Cluster state is driven from Git using a root Argo CD application that reconciles child Application definitions for platform services and workloads. Direct ad-hoc changes over SSH are avoided in favor of tracked commits and standard Kubernetes tooling (kubectl, k9s).
  • K3s-Bundled Traefik v3 for Ingress: Rather than introducing a heavy enterprise service mesh or custom ingress stack for a small cluster, the built-in Traefik v3 controller handles routing and TLS termination. Its administrative dashboard is kept off public services and accessed only via local port-forwarding when needed.
  • Automated TLS via cert-manager: Certificate lifecycle management is separated from the ingress controller using cert-manager and Let’s Encrypt ClusterIssuer automation.
  • Encrypted Secrets in Git: Sensitive values for GitOps-managed workloads are stored using SealedSecret resources rather than plaintext manifests.
  • VPN-Only Home LAN Connectivity: The public VPS runs a WireGuard gateway (UDP 443) peered with an OpenWrt router at home. The home router initiates and maintains the tunnel, eliminating any need for a public home IPv4 address while keeping NAS, router, Home Assistant, and IoT administration strictly private.

Platform Services

  • Observability: kube-prometheus-stack with Prometheus, Alertmanager, and Grafana dashboards, complemented by InfluxDB and Telegraf for IoT and sensor time-series metrics.
  • Messaging: Eclipse Mosquitto running inside the cluster, exposing authenticated WebSockets over TLS for external IoT clients while keeping native MQTT internal to the cluster.
  • Cluster Visibility: Headlamp deployed via GitOps for lightweight Kubernetes inspection.

Operating Principles

  • Separate application build pipelines from live cluster deployment manifests.
  • Keep container workloads unprivileged with explicit resource requests/limits and health probes.
  • Prefer boring, well-documented components that are straightforward to rebuild from Git.
← Back to all projects