Skip to content

Commit f897c7e

Browse files
feat: Add Telemetry Dashboard with Docker and deployment configuration
1 parent d829c7d commit f897c7e

File tree

6 files changed

+595
-0
lines changed

6 files changed

+595
-0
lines changed

.github/workflows/deploy.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ jobs:
3030
path: visual_controller
3131
application: "visual-controller"
3232
environment: "Visual-controller-env"
33+
- service: telemetry-dashboard
34+
path: telemetry_dashboard
35+
application: "telemetry-dashboard"
36+
environment: "Telemetry-dashboard-env"
3337
steps:
3438
- name: Checkout repository
3539
uses: actions/checkout@v4

telemetry_dashboard/Dockerfile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
FROM python:3.11-slim
2+
3+
ENV PYTHONDONTWRITEBYTECODE=1 \
4+
PYTHONUNBUFFERED=1
5+
6+
WORKDIR /app
7+
8+
COPY requirements.txt .
9+
RUN pip install --no-cache-dir -r requirements.txt
10+
11+
COPY . .
12+
13+
CMD ["gunicorn", "app:server", "--bind", "0.0.0.0:8000"]

telemetry_dashboard/Procfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
web: gunicorn app:server --bind 0.0.0.0:$PORT --timeout 120

telemetry_dashboard/README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Telemetry Dashboard
2+
3+
This Dash + Plotly application renders real-time telemetry from the tank fleet. It subscribes to the Redis `tank_status` stream (via the control broker) and visualizes:
4+
5+
- Environment readings (temperature/humidity)
6+
- GPS trail and speed
7+
- Basic connection metadata (satellites, HDOP, timestamps)
8+
9+
## Configuration
10+
11+
Environment variables:
12+
13+
| Variable | Default | Description |
14+
| --- | --- | --- |
15+
| `REDIS_URL` | `redis://localhost:6379/0` | Connection string for the telemetry Redis instance |
16+
| `REDIS_STATUS_STREAM` | `tank_status` | Redis stream containing incoming telemetry payloads |
17+
| `HISTORY_LIMIT` | `500` | Maximum number of samples kept in memory per process |
18+
| `REFRESH_INTERVAL_MS` | `3000` | Polling interval for the Dash client |
19+
20+
## Development
21+
22+
```bash
23+
cd telemetry_dashboard
24+
python -m venv .venv
25+
source .venv/bin/activate
26+
pip install -r requirements.txt
27+
python app.py
28+
```
29+
30+
Visit http://127.0.0.1:8050/ to view the dashboard.
31+
32+
## Deployment
33+
34+
Deploy like the other Elastic Beanstalk services:
35+
36+
```bash
37+
zip -r telemetry-dashboard.zip .
38+
aws elasticbeanstalk create-application-version ... # etc.
39+
```
40+
41+
The provided `Dockerfile` and `Procfile` mirror the other services in this repository for compatibility with the existing pipeline.

0 commit comments

Comments
 (0)