Files
ophion/install.sh
bigtux 5b662cf12f feat: Initial OPHION structure
- Go backend with Fiber framework
- Agent for metrics collection
- Docker Compose for self-hosted
- Auth middleware (JWT + API Keys)
- Rate limiting
- Install script
2026-02-05 21:35:47 -03:00

50 lines
1.3 KiB
Bash
Executable File

#!/bin/bash
set -e
echo "🐍 OPHION - Observability Platform Installer"
echo "============================================="
# Check Docker
if ! command -v docker &> /dev/null; then
echo "❌ Docker not found. Installing..."
curl -fsSL https://get.docker.com | sh
fi
# Check Docker Compose
if ! command -v docker-compose &> /dev/null && ! docker compose version &> /dev/null; then
echo "❌ Docker Compose not found. Please install it."
exit 1
fi
# Create directory
INSTALL_DIR="${OPHION_DIR:-/opt/ophion}"
mkdir -p "$INSTALL_DIR"
cd "$INSTALL_DIR"
# Download docker-compose
echo "📥 Downloading OPHION..."
curl -fsSL https://raw.githubusercontent.com/bigtux/ophion/main/deploy/docker/docker-compose.yml -o docker-compose.yml
# Generate secrets
JWT_SECRET=$(openssl rand -hex 32)
echo "JWT_SECRET=$JWT_SECRET" > .env
# Start services
echo "🚀 Starting OPHION..."
docker compose up -d
echo ""
echo "✅ OPHION installed successfully!"
echo ""
echo "📊 Dashboard: http://localhost:3000"
echo "🔌 API: http://localhost:8080"
echo ""
echo "Next steps:"
echo "1. Open http://localhost:3000 in your browser"
echo "2. Create your admin account"
echo "3. Add your first server with the agent"
echo ""
echo "To install the agent on a server:"
echo " curl -fsSL https://get.ophion.io/agent | bash"
echo ""