Docker Infrastructure Documentation¶
Application error: a client-side exception has occurred while loading gymplan.rbnk.uk (see the browser console for more information).
Welcome to the comprehensive documentation for the self-hosted Docker infrastructure on rbnk.uk.
Auto-rebuild enabled: Documentation automatically rebuilds when changes are detected.
🆕 What's New¶
December 2025¶
- CodeScribe - Code documentation generator with REST API, MCP server, and CLI for AI context generation (docs)
- Browser Use - LLM-powered browser automation service with REST API, Gradio UI, and MCP integration (docs)
- Claude Code Safety Hooks - Comprehensive safety infrastructure with pre/post tool hooks, audit logging, and dangerous command blocking (docs)
- Backup Infrastructure Overhaul - Enhanced dual backup system with Prometheus metrics, Grafana dashboards, and improved R2 integration
- Supabase Enhancements - Added Realtime, Edge Functions, Analytics, Vector (logging), and ImgProxy services
November 2025¶
- Zurg + Jellyfin - Media streaming stack with Real-Debrid integration and hardware transcoding
- Docs Auto-Rebuild - Automatic documentation rebuilding on git push with llms.txt generation
August 2025¶
- Iodine DNS Tunnel - DNS tunneling service optimized for captive portal bypass (port 53 with AdGuard forwarding)
- Coolify-Traefik Bridge - Automated routing of Coolify services through main Traefik with DNS record creation
- Authentik SSO - Single sign-on with dual-route authentication strategy
- StackWiz MCP - Model Context Protocol server enabling AI-powered Docker stack management
- Monitoring Overhaul - Comprehensive Prometheus, Grafana, Loki, and AlertManager improvements
📚 Documentation Index¶
Architecture¶
- System Overview - High-level architecture and component relationships
- Network Topology - Docker networks, Traefik routing, SSL setup
- Storage Strategy - Dual-disk configuration and data management
- Key Decisions - Architectural decisions and their rationale
Services¶
Core Infrastructure¶
- Traefik - Reverse proxy and SSL termination
- Monitoring Stack - Prometheus, Grafana, Loki, and AlertManager
- Notification Stack - Apprise, ntfy, Mailrise, and Uptime Kuma
- AdGuard Home - Network-wide DNS filtering and ad blocking
- Iodine DNS Tunnel - DNS tunneling service for bypassing restrictive firewalls
Data & Development¶
- Supabase - PostgreSQL-based backend-as-a-service
- Pocketbase - Lightweight SQLite alternative
- Gitea - Self-hosted Git service with GitHub mirroring
AI & Automation¶
- Browser Use - LLM-powered browser automation with REST API and Gradio UI
- CodeScribe - Code documentation generator for AI context with MCP server
- Ollama - Local LLM service with dual-disk setup
- Open WebUI - AI chat interface
- LiteLLM - Unified LLM API proxy
- LiteLLM Virtual Keys - Virtual keys implementation for secure LLM access
- n8n - Workflow automation platform with visual programming interface
- StackWiz MCP - Model Context Protocol server for Docker stack management
Storage & Backup¶
- Rclone - Cloud storage backup and synchronization service with infrastructure backups to Cloudflare R2
- Paperless-AI - AI-powered document management with intelligent search
Media & Streaming¶
- Zurg + Jellyfin - Media streaming stack with Real-Debrid integration
- AIOStreams - Unified streaming addon management
- Metube - Web-based YouTube downloader for video and audio content
Utilities¶
- Watchtower - Automated container updates with service exclusions
Operations¶
- Backup & Restore - Backup procedures and disaster recovery
- DNS Management - Cloudflare DNS configuration and management
- Monitoring - Health checks, logs, and metrics
- Security - Permissions, secrets management, hardening
- Safety Hooks - Claude Code safety infrastructure and audit logging
- Maintenance - Updates, disk management, troubleshooting
- Proxmox Port Forwarding - Port forwarding configuration and automation
- Tailscale Access - VPN access configuration
Development¶
- Quickstart Guide - Get started with development quickly
- StackWiz Guide - Using the stack creation wizard
- Adding Services - How to add new services to the infrastructure
- Claude Code Configuration - AI assistant skills, agents, commands, and hooks
- Troubleshooting - Common issues and solutions
Troubleshooting¶
- SSL Certificate Issues - Diagnosing and fixing SSL/TLS problems
Security¶
- Git Security - Dual repository security model, secret filtering, and sync workflows
Version Control¶
- Git Workflow - Development workflow with Gitea primary and GitHub mirror
- Gitea-GitHub Sync - Automated secure synchronization process
Reference¶
- Ports & Services - Complete service port mapping
- Environment Variables - All configuration variables
- Commands Quick Reference - Common commands cheatsheet
🚀 Quick Start¶
- Deploy a new service: Use
stackwizto create a new service stack - Access services: All services available at
https://*.rbnk.uk - View logs:
docker compose -f SERVICE/docker-compose.yml logs -f - Backup data: Run
/srv/dockerdata/_scripts/SERVICE-backup.sh - Access Git: Browse code at
https://gitea.rbnk.ukor clone via SSH/HTTPS - AI Automation: Use StackWiz MCP with Claude to create and manage Docker stacks automatically
🏗️ Infrastructure Overview¶
┌─────────────────────────────────────────────────────────────┐
│ Internet │
└────────────────────┬────────────────────────────────────────┘
│ HTTPS (*.rbnk.uk)
┌─────────┴──────────┐
│ Cloudflare DNS │
│ (SSL Certificates)│
└─────────┬──────────┘
│
┌─────────┴──────────┐
│ Traefik │ ← Reverse Proxy
│ (Docker Labels) │ Auto-SSL
└─────────┬──────────┘
│
┌────────────┴────────────┬─────────────┬──────────────┐
│ │ │ │
┌───────┴────────┐ ┌────────┴───────┐ ┌──┴────────┐ ┌──┴────────┐
│ Supabase │ │ Open WebUI │ │ LiteLLM │ │ Gitea │
│ (PostgreSQL) │ │ (AI Chat UI) │ │ (LLM API) │ │ (Git) │
└────────────────┘ └────────────────┘ └───────────┘ └───────────┘
┌────────────────┐ ┌─────────────────────┐ ┌────────────────┐
│ Rclone │ │ Monitoring Stack │ │ n8n + MCP │
│ (Cloud Backup) │ │ (Prometheus/Grafana)│ │ (Automation) │
│ & R2 Storage │ └─────────────────────┘ └────────────────┘
└────────────────┘
┌─────────────────────────────────────────────────────────────────┐
│ Notification Stack │
│ (Apprise + ntfy + Mailrise + Uptime Kuma) │
└─────────────────────────────────────────────────────────────────┘
💾 Storage Layout¶
- System Disk (
/dev/sda- 100GB): OS and system files (29% used) - Data Disk (
/dev/sdb- 500GB):/srv/dockerdata- All Docker data (39% used)
🔐 Version Control¶
The infrastructure uses a dual repository strategy for secure code management:
- Private Repository (Gitea):
https://gitea.rbnk.uk- Contains all files including sensitive configuration - Public Repository (GitHub): Public mirror with sensitive files automatically filtered out
- Automated Sync: Changes pushed to Gitea are automatically synced to GitHub with security filtering
- Access: Gitea provides full Git functionality with web UI for code browsing and management
🔑 Key Principles¶
- Service Isolation: Each service in its own directory with dedicated
docker-compose.yml - Automatic SSL: Traefik + Cloudflare handles all SSL certificates
- Network Security: Internal services (databases) not exposed publicly
- Standardized Structure: Consistent patterns across all services
- Infrastructure as Code: Everything configured through files, not UIs
- Secure Version Control: Private Gitea instance with automated public GitHub sync
⚠️ Important Notes¶
- Disk Space: System disk (100GB, 29% used), Data disk (500GB, 39% used) - healthy capacity
- Backups: Automated dual backup system - cloud backups at 2 AM, infrastructure backups to R2 at 4 AM
- Secrets: Stored in
.envfiles - ensure proper permissions (640) - Container Updates: Watchtower handles automatic updates but critical services (databases, infrastructure) are protected
- Git Security: Never commit sensitive files to public repos - use Gitea for private code
📝 Contributing to Docs¶
When adding documentation: 1. Include the "why" not just the "how" 2. Add examples where helpful 3. Cross-reference related documentation 4. Update this index when adding new guides
Last Updated: December 2025 - Added CodeScribe code documentation service with MCP server