A cloud-native monitoring solution that collects meteorological data, generates visual trends, and provides automated alerting.
This project implements an end-to-end data pipeline:
- Ingestion: Telegraf collects weather and air quality data from open APIs.
- Storage: Time-series data is stored in InfluxDB.
- Visualization: A custom Python application generates high-quality trend graphs and synchronizes them to a static web host.
- Observability: Prometheus monitors system health and metric thresholds.
- Alerting: A Go-based Telegram Proxy translates Alertmanager webhooks into instant messenger notifications.
graph LR
subgraph "Data Sources"
APIs[Weather & Air Quality APIs]
end
subgraph "Kubernetes Cluster"
T[Telegraf Agent] --> I[(InfluxDB)]
P[Python Grapher] -- Queries --> I
Prom[Prometheus] -- Scrapes --> T
Prom -- Alerts --> GP[Go Telegram Proxy]
end
subgraph "Output"
P -- Uploads --> NC[Neocities Hosting]
GP -- Sends --> TG[Telegram Bot]
end
A Python service that automates data visualization.
- Engine:
matplotlib&seabornfor professional-grade aesthetics. - Process: Fetches temperature, pressure, humidity, and PM2.5 data.
- Delivery: Generates 2-day and 2-week rolling windows and pushes them to Neocities via API.
A lightweight Go microservice acting as an Alertmanager-to-Telegram bridge.
- Translates Prometheus alerting payloads into human-readable messages.
- Supports
firingandresolvedstatuses with custom formatting.
- Helm Charts: Standardized deployment templates for all services.
- Makefile: Unified command-line interface for the entire lifecycle.
- Telegraf Config: Specialized input plugins for meteorological data.
- A Kubernetes cluster with
kubectlandhelmconfigured. - InfluxDB instance (local or remote).
- API tokens for Neocities and a Telegram Bot.
-
Manage Secrets: Populate
.secrets/secrets.envand.secrets/secrets-telegram.env, then run:make secrets
-
Build & Ship Images:
make push make push-proxy
-
Deploy Applications:
make deploy-all
-
Enable Monitoring:
make deploy-monitoring
make build-all: Build all Docker images.make deploy-local: Quick deployment with development tags.make logs: Stream logs from the weather application.make sync-config: Update theindex.htmlfrontend via ConfigMap.make undeploy: Clean up all resources from the cluster.
- Implement
plt.close()in Python to prevent memory leaks. - Add basic authentication to the Telegram Proxy endpoint.
- Optimize the Docker image size for the Go proxy.
- Integrate Grafana for real-time interactive dashboards.