Files
weatherstation-datacollector/docker-compose.yml
olaf f55c1fe6f1 Pool sensor v2: VCC monitoring, database resilience, receiver improvements
- Added voltage monitoring table and storage pipeline
- Extended pool payload to 17 bytes with VCC field (protocol v2)
- Improved database connection pool resilience (reduced pool size, aggressive recycling, pool disposal on failure)
- Added environment variable support for database configuration
- Fixed receiver MQTT deprecation warning (CallbackAPIVersion.VERSION2)
- Silenced excessive RSSI status logging in receiver
- Added reset flag tracking and reporting
- Updated Docker compose with DB config and log rotation limits
2026-01-25 11:25:15 +00:00

39 lines
1.1 KiB
YAML

version: '3.8'
services:
data-collector:
build:
context: .
dockerfile: Dockerfile
environment:
- PI_HOST=${PI_HOST}
- PI_USER=${PI_USER:-pi}
- SSH_KEY_PATH=/workspace/.ssh/id_rsa
- STALL_WINDOW_SECONDS=${STALL_WINDOW_SECONDS:-300}
- RESTART_COOLDOWN_SECONDS=${RESTART_COOLDOWN_SECONDS:-3600}
- DB_HOST=${DB_HOST:-192.168.43.102}
- DB_PORT=${DB_PORT:-3306}
- DB_USER=${DB_USER:-weatherdata}
- DB_PASSWORD=${DB_PASSWORD:-cfCUswMHfK82!}
- DB_NAME=${DB_NAME:-weatherdata}
- DB_CONNECT_TIMEOUT=${DB_CONNECT_TIMEOUT:-5}
volumes:
- /volume1/docker/weatherstation:/workspace
- /volume1/docker/weatherstation/data:/workspace/data
- /volume1/docker/weatherstation/secrets/id_rsa:/workspace/.ssh/id_rsa:ro
- /volume1/docker/weatherstation/secrets/known_hosts:/workspace/.ssh/known_hosts:ro
restart: unless-stopped
command: python datacollector.py
logging:
driver: json-file
options:
max-size: "5m"
max-file: "3"
networks:
- data-net
stdin_open: true
tty: true
networks:
data-net:
driver: bridge