Version: 0.2.0
Warning
This project is not ready for public consumption and is under heavy development.
Gearbox is a general-purpose monitoring and management platform with a gear-based architecture. It uses gearbox-agent (a separate Go binary) installed on servers and workstations to gather data and act as a secure agent and controller.
Key Capabilities:
- Monitor multiple servers/workstations from a single dashboard
- Gear-based feature system
- Real-time updates via WebSocket
- Web UI configuration
- Auto-discovery of services on monitored hosts
IMPORTANT: Gearbox is NOT an HAProxy-specific tool. It is a universal monitoring platform. HAProxy monitoring is just one gear among many.
New to Gearbox? Follow our comprehensive Getting Started Guide for step-by-step instructions on:
- Installing the Gearbox dashboard and agent
- Generating and configuring API keys
- Adding your first monitored server
- Enabling gears
The guide includes detailed examples, troubleshooting tips, and best practices for production deployments.
- Go 1.25 or later
- Node.js (for frontend assets)
- Templ for template generation
cd gearbox
make devVisit http://localhost:3000
cd gearbox-agent
make build
./bin/gearbox-agent# Using Docker
docker run -d \
--name gearbox-agent \
-p 8405:8405 \
-v gearbox-agent-data:/var/lib/gearbox-agent \
ghcr.io/sarg3nt/gearbox/gearbox-agent:latest
# Using Docker Compose
cd gearbox-agent
docker-compose up -dAgent runs on https://localhost:8405
See gearbox-agent/README.md for installation options and gearbox-agent/docs/docker.md for Docker-specific configuration.
gearbox-agent (gearbox-agent/)
- Go binary installed on monitored servers/workstations
- Runs on port 8405 (HTTPS)
- Gear-based collectors auto-discover services
- Exposes REST API and WebSocket
- Works on ANY Linux system
gearbox (gearbox/)
- Web dashboard application
- Runs on port 3000
- Connects to multiple gearbox-agent instances
- Gear-based features
Monitored Server → gearbox-agent (collects data) → API/WebSocket → gearbox dashboard → Browser
Gear = Self-contained feature module with pages, API handlers, and templates
Framework = Shared services and building blocks
Framework provides:
- Agent client for API/WebSocket communication
- Database access and models
- Authentication/authorization
- Event bus for real-time updates
- Shared UI components (graphs, tables, panels, cards)
- Template system (Templ)
Gears provide:
- Pages and routes
- API handlers
- Domain-specific logic
- Self-contained functionality
| Gear | Purpose |
|---|---|
| HAProxy | HAProxy monitoring and stats |
| Metrics | System metrics (CPU, memory, disk, network, load, uptime) |
| Services | Systemd service monitoring |
| Certificates | TLS certificate tracking |
| Logs | Log aggregation and viewing |
| Traffic | Traffic analysis and visualization |
| Alerts | Alert management and rules |
| OS Updates | Package update monitoring |
Total: 8 gears
Located in gearbox/ directory.
After ANY change, MUST run:
cd gearbox && make templ-generate && make buildFor local development with hot reload:
cd gearbox && make devKey directories:
internal/framework/- Shared infrastructureinternal/gears/- Feature gearsinternal/templates/- Templ templatesstatic/- JavaScript, CSS, assets
Located in gearbox-agent/ directory.
Build:
cd gearbox-agent && make buildKey directories:
internal/api/- REST API handlersinternal/collector/- Data collectioninternal/gears/- Agent-side gearscmd/gearbox-agent/- Entry point
Environment variables in /etc/default/gearbox-agent:
# Server
HAPROXY_AGENT_LISTEN=0.0.0.0:8405
HAPROXY_AGENT_DATA_DIR=/var/lib/gearbox-agent
HAPROXY_AGENT_LOG_LEVEL=info
# TLS
HAPROXY_AGENT_TLS_CERT=/path/to/cert.crt
HAPROXY_AGENT_TLS_KEY=/path/to/key.keyOne gearbox dashboard can monitor many servers:
- Install gearbox-agent on each server to monitor
- Configure server in gearbox via Settings > Servers
- Enable desired gears for each server
- Gear pages display data from selected server
Primary Sources:
- README.md - This file (overview and quick start)
- CLAUDE.md - Development guidance for Claude Code
- docs/gears.md - Complete gear architecture documentation
- TASKS.md - Active development tasks
- gearbox/docs/development.md - Local development guide
Agent Documentation:
- gearbox-agent/README.md - Agent overview
- gearbox-agent/docs/ - API documentation
Research & Historical:
- docs/research/ - Research and analysis documents
- Container and stack management (GitOps-focused Portainer alternative)
- Multi-server orchestration
- Infrastructure-as-code integration
- Additional gears for databases, web servers, etc.
This is a private repository. Development guidelines are in CLAUDE.md.
This project is licensed under the Elastic License v2 (ELv2).
See LICENSE file for details.
You are free to:
- Use the software for personal, academic, or commercial purposes
- Deploy it internally within your organization
- Run it on servers, workstations, or embedded systems
- Modify it for internal use
- Embed it into internal tooling or workflows
- Host and use an unmodified version of the software for free
You may not:
- Offer the software as a hosted or managed service where the software itself is the primary value being sold
- Rebrand, resell, or offer it as a competing commercial product or service
If you wish to offer this software (or a modified version of it) as a managed or hosted service, commercial licensing is available. Please contact dave@sarg3.net for more information.
This license is designed to be friendly to internal enterprise use while protecting the project from being resold or rebranded as a competing service.