System Architecture โ 3 Layers
NODES
๐ฅ๏ธ
AWS Instances
eu-north ยท eu-west
๐ฅ๏ธ
Hetzner Nodes
Dedicated Servers
๐ฅ๏ธ
Service Nodes
Application Hosts
โฒ
FastAPI :880 โ JSON metrics (CPU, RAM, Net, Uptime, Traffic)
โผ
COLLECT
๐ฅ
Data Collectors
Multiprocessing Pool
๐
CSV Store
Per-Provider Files
CSV Read ยท 0.5s Refresh
โผ
DISPLAY
๐ฅ๏ธ
Terminal TUI
Curses ยท Color-coded
๐
Web Dashboard
PHP ยท Long-Polling
๐
Alert Engine
Threshold Rules
Key Features
โก
Parallel Data Collection
Multiprocessing Pool fetches metrics from all servers simultaneously. Scales to 30+ nodes with no bottleneck.
๐ฅ๏ธ
Curses Terminal UI
Full-screen ncurses dashboard with color-coded health indicators, scrollable sections, and 0.5s auto-refresh.
๐
Multi-Provider View
Unified view across AWS, Hetzner, and custom nodes โ each with provider-specific health thresholds and logic.
๐จ
Smart Anomaly Rules
Context-aware alerts: high CPU + low traffic = problem. High traffic + high CPU = normal. No false positives.
๐
FastAPI Resource Agent
Async agent on each node exposing CPU, RAM, network speed, traffic, and service uptime via REST endpoint.
๐ก๏ธ
Auto-Healing Triggers
Automatic service restarts when RAM exceeds 96%. Service management endpoints for remote reboot and restart.
Tech Stack
Python
FastAPI
asyncio
Multiprocessing
ncurses
Pandas
psutil
uvicorn
REST API
CSV Pipeline
Subprocess Mgmt
Telegram Alerts
System Scale