The Practical Home DevOps Lab: Self-hosting a CI/CD Pipeline in a Realistic Homelab
If you want to learn DevOps properly, you don’t need to chase cloud credits or pretend your laptop is a production cluster. You build it. You break it. You fix it. A home lab is where you learn to ship code, test infrastructure, and operate systems with the same discipline you’ll need in production—without burning through a fortune on cloud bills or trying to fake it with toy projects. In this guide, I’ll walk you through a practical, repeatable setup: a self-hosted CI/CD and DevOps stack that you can actually operate, with honest tradeoffs, concrete steps, and the rough edges you’ll hit in the wild.
Hook: Why bother self-hosting a CI/CD pipeline at home? Because pipelines are not just about the build step; they’re about reproducibility, security, and automation across the full lifecycle. When your build, test, package, and deploy pipelines live behind your own firewall, you own the cadence, the cost, and the failure modes. That’s where a homelab shines: it forces you to confront the hard parts—storage, networking, backups, and security—before you encounter them in production.
Plan: define the scope first, then choose a pragmatic stack you can grow into. The core: a Git hosting + CI/CD engine, a lightweight cluster for deployment targets, observability for visibility, and backups that survive disasters. Everything else (secret management, registry, logs, canary deployments) can be layered incrementally as you gain confidence.
1) Start small, with a sane target
- Target stack (minimum viable):
- Git hosting with integrated CI/CD
- A small, self-hosted Kubernetes cluster (or at least a few containers) for deploying apps
- Built-in container registry (or use the Git hosting registry)
- Basic monitoring and alerting
- Regular backups and disaster recovery
- Realistic growth plan:
- Day 1–14: Proxmox or equivalent hypervisor, one or two VMs, GitLab CE with CI, a simple app, and a sample pipeline.
- Day 15–45: Lightweight Kubernetes (K3s) for deployment targets, add monitoring (Prometheus + Grafana), add a TLS reverse proxy.
- Day 46–90: Backups, offsite replication, more pipelines, a second registry, more automation (Ansible/Terraform), security hardening.
2) Hardware and network: what you actually need
- Hardware:
- A single, solid box can do a lot: 8–16 cores, 32–64 GB RAM is comfortable for a small team’s worth of pipelines and a Kubernetes cluster. If you’re tight on space, a 4-core/16GB box can run a GitLab CE instance and a tiny cluster for learning, but you’ll want more headroom for concurrent jobs.
- Storage: NVMe for the OS and home directory, plus 2–6 TB of HDD/SSD storage for data volumes, artifacts, and backups. Use separate disks for OS, data, and backups if possible.
- Network: a robust home network with a dedicated management network is nice, but not strictly required. A small switch with VLAN support helps if you’re segmenting traffic; otherwise, virtual networks (in Proxmox) do the job.
- Networking considerations:
- Reserve a fixed internal DNS name for your GitLab server (e.g., gitlab.lab.local) and a public DNS