6f9657a3a8060bf390ed8f1ab66622c491173447
## New Features ### Universal Instrumentation Container - Created deploy/instrumentation/ with Dockerfile that downloads OTel agents for: - .NET (glibc and musl/Alpine versions) - Node.js (with auto-instrumentation package) - Python (bootstrap script + requirements) - Java (javaagent JAR) - Go (example code for compile-time instrumentation) - PHP (composer package + init script) ### Universal instrument.sh Script - Auto-detects application language from running processes - Generates docker-compose snippets for each language - Supports: dotnet, nodejs, python, java, go, php - Usage: ./instrument.sh <container> [language] [otlp_endpoint] ### Improved docker-compose.yml - Added instrumentation init container with shared volume - Added AGENT_KEY environment variable for proper auth - Added ophion-agent service for host metrics collection - Named containers for easier management - Added ophion-network for service discovery ### Documentation - Created docs/QUICK_START.md with: - Single-command installation - Instrumentation guide for all languages - Troubleshooting section - Authentication guide ### Auth Fixes - Server now properly validates AGENT_KEY for agent authentication - OTel Collector configured with AGENT_KEY for forwarding to server - Fixed 401 errors when agents connect ## Files Changed - docker-compose.yml: Complete stack with all services - deploy/instrumentation/*: Universal OTel agent container - deploy/docker/otel-collector-config.yaml: Fixed auth headers - instrument.sh: Universal instrumentation script - docs/QUICK_START.md: Complete quick start guide - README.md: Updated with new features - .env.example: Added AGENT_KEY ## Testing - Go code compiles successfully - Docker images build correctly - All changes are backwards compatible
🐍 OPHION
Open Source Observability Platform — AI-Powered Monitoring
O que é o OPHION?
OPHION é uma plataforma de observabilidade que combina métricas, logs e traces com inteligência artificial para monitoramento proativo de infraestrutura.
✨ Diferenciais
| Feature | OPHION | Datadog | Grafana |
|---|---|---|---|
| Métricas, Logs, Traces | ✅ | ✅ | ✅ |
| Copilot com IA | ✅ | ❌ | ❌ |
| Auto-Healing | ✅ | ❌ | ❌ |
| Correlação de Alertas com IA | ✅ | 💰 | ❌ |
| Previsões de Capacidade | ✅ | 💰 | ❌ |
| Open Source | ✅ | ❌ | ✅ |
| Auto-instrumentação Universal | ✅ | 💰 | ❌ |
🚀 Quick Start (1 Comando)
git clone https://github.com/bigtux/ophion.git && cd ophion && docker compose up -d
Aguarde ~2 minutos e acesse:
- Dashboard: http://localhost:3000
- API: http://localhost:8080
- OTLP (traces): localhost:4317 (gRPC) / localhost:4318 (HTTP)
📖 Guia Completo de Quick Start
🔧 Instrumentar Sua Aplicação
Script Universal
# Auto-detecta a linguagem
./instrument.sh my-container
# Ou especifique
./instrument.sh my-container nodejs
./instrument.sh my-container python
./instrument.sh my-container java
./instrument.sh my-container dotnet
Linguagens Suportadas
| Linguagem | Método | Complexidade |
|---|---|---|
| .NET | Auto-instrumentation | 🟢 Zero code |
| Node.js | Auto-instrumentation | 🟢 Zero code |
| Python | Auto-instrumentation | 🟢 Zero code |
| Java | Java Agent | 🟢 Zero code |
| Go | SDK (compile-time) | 🟡 Pequenas mudanças |
| PHP | SDK | 🟡 Pequenas mudanças |
📋 Requisitos
| Recurso | Mínimo | Recomendado |
|---|---|---|
| CPU | 2 cores | 4+ cores |
| RAM | 4 GB | 8+ GB |
| Disco | 20 GB SSD | 100+ GB SSD |
| Docker | 20.10+ | Latest |
| Docker Compose | v2+ | Latest |
📦 Arquitetura
┌─────────────────────────────────────────────────────────────────┐
│ YOUR APPLICATIONS │
│ ┌─────────┐ ┌─────────┐ ┌─────────┐ ┌─────────┐ ┌─────────┐ │
│ │ Node.js │ │ Python │ │ Java │ │ .NET │ │ Go │ │
│ └────┬────┘ └────┬────┘ └────┬────┘ └────┬────┘ └────┬────┘ │
│ │ │ │ │ │ │
│ └───────────┴───────────┼───────────┴───────────┘ │
│ │ OTLP (4317/4318) │
└───────────────────────────────┼─────────────────────────────────┘
│
┌───────────────────────────────┼─────────────────────────────────┐
│ OPHION STACK ▼ │
│ ┌─────────────────────────────────────────────────┐ │
│ │ OpenTelemetry Collector │ │
│ │ (process, batch, export) │ │
│ └─────────────────────────┬───────────────────────┘ │
│ │ │
│ ┌────────────────┐ ▼ ┌────────────────┐ │
│ │ Dashboard │◄──► Server ◄──►│ PostgreSQL │ │
│ │ (Next.js) │ (Go API) │ ClickHouse │ │
│ └────────────────┘ │ Redis │ │
│ └────────────────┘ │
└─────────────────────────────────────────────────────────────────┘
🔐 Autenticação
Para Aplicações (OTLP)
Envie traces para o OpenTelemetry Collector (porta 4317/4318) - sem auth necessário.
Para API
Use AGENT_KEY para agents ou JWT para dashboard:
# .env
AGENT_KEY=my-secret-key
📦 Estrutura do Projeto
ophion/
├── docker-compose.yml # Stack completa
├── instrument.sh # Script de instrumentação
├── cmd/
│ ├── server/ # API Server (Go)
│ └── agent/ # Agent de coleta
├── dashboard/ # Frontend (Next.js)
├── deploy/
│ ├── docker/ # Docker configs
│ └── instrumentation/ # Container com agents OTel
├── internal/ # Código interno Go
└── docs/
├── QUICK_START.md # ⭐ Comece aqui
├── INSTALL.md
└── SECURITY.md
📖 Documentação
- ⭐ Quick Start - Comece em 5 minutos
- Instalação Avançada
- Segurança
- Manual Completo
🛠️ Desenvolvimento
# Clonar
git clone https://github.com/bigtux/ophion.git
cd ophion
# Compilar Go
go build ./...
# Rodar localmente
docker compose up -d postgres redis
go run ./cmd/server
# Testes
go test ./...
🆘 Suporte
- Issues: https://github.com/bigtux/ophion/issues
- Email: suporte@ophion.com.br
📄 Licença
AGPL-3.0 (Community Edition)
Made with 🖤 in Brazil
Description
🐍 OPHION - Open Source Observability Platform with AI-Powered Monitoring
https://ophion.com.br
Languages
Go
46.9%
TypeScript
26.6%
Shell
15.4%
HTML
6.9%
Dockerfile
2.9%
Other
1.3%