fb31bcb0a36f94e1b2e10e2112e0750bd449ccbf
homelab-infra
GitOps-managed infrastructure for homelab services using Docker Compose and Traefik for routing.
Overview
This repository manages a homelab setup with multiple self-hosted services. It uses GitOps principles where infrastructure as code is version-controlled, and documentation is automatically generated from configuration files using MkDocs.
Key Features
- GitOps Workflow: All infrastructure configurations are stored in Git
- Automated Documentation: MkDocs site built from actual config files
- Service Management: Makefile for easy service control
- Environment Sync: Pre-commit hooks ensure .env files stay in sync
- Backup Integration: Restic-based backups for data protection
Services
Currently includes: Gitea (Git hosting), Nextcloud (cloud storage), Devbox (development container), Obsidian LiveSync (CouchDB), Traefik (reverse proxy), and Whoami (test service).
Getting Started
- Clone the repo
- Copy environment templates:
make init-env - Edit
.envfiles with your secrets - Create Docker networks:
docker network create web - Start services:
make up
Documentation
Full documentation is available at the MkDocs site or build locally with make docs.
Directory Structure
homelab-infra/
├── Makefile # Service management commands
├── backup.sh # Restic backup script
├── docs/ # MkDocs documentation source
├── mkdocs.yml # MkDocs configuration
├── scripts/ # Utility scripts
└── [service]/ # Per-service configurations
├── docker-compose.yml
├── .env.example
└── README.md
Description
Languages
Python
82.4%
Makefile
14.5%
Shell
3.1%