feat(simulator): Grafana monitoring over generated Parquet
Monitoring compose profile: dependency-free Prometheus exporter that scans the Parquet output with DuckDB (rows, detections, pose frames, battery, RSSI, link distance, bytes on disk), Prometheus scrape config and a provisioned Grafana dashboard. Demonstrates the observability doctrine: fleet statistics derived from the data platform itself.
This commit is contained in:
@@ -15,3 +15,41 @@ services:
|
||||
BROADCAST_ADDR: ${BROADCAST_ADDR:-255.255.255.255}
|
||||
volumes:
|
||||
- ./data:/data
|
||||
|
||||
# --- Monitoring profile: docker compose --profile monitoring up ---
|
||||
|
||||
exporter:
|
||||
build: .
|
||||
profiles: [monitoring]
|
||||
command: ["python", "monitoring/exporter.py"]
|
||||
environment:
|
||||
DATA_DIR: /data
|
||||
SCAN_INTERVAL_S: "5"
|
||||
volumes:
|
||||
- ./data:/data:ro
|
||||
- ./monitoring:/app/monitoring:ro
|
||||
ports:
|
||||
- "9105:9105"
|
||||
|
||||
prometheus:
|
||||
image: prom/prometheus:v2.53.0
|
||||
profiles: [monitoring]
|
||||
volumes:
|
||||
- ./monitoring/prometheus.yml:/etc/prometheus/prometheus.yml:ro
|
||||
ports:
|
||||
- "9090:9090"
|
||||
|
||||
grafana:
|
||||
image: grafana/grafana:11.1.0
|
||||
profiles: [monitoring]
|
||||
environment:
|
||||
GF_AUTH_ANONYMOUS_ENABLED: "true"
|
||||
GF_AUTH_ANONYMOUS_ORG_ROLE: Admin
|
||||
GF_AUTH_DISABLE_LOGIN_FORM: "true"
|
||||
volumes:
|
||||
- ./monitoring/grafana/provisioning:/etc/grafana/provisioning:ro
|
||||
- ./monitoring/grafana/dashboards:/var/lib/grafana/dashboards:ro
|
||||
ports:
|
||||
- "3000:3000"
|
||||
depends_on:
|
||||
- prometheus
|
||||
|
||||
Reference in New Issue
Block a user