Files
bom-local-card/docker-compose.test.yml
T
alex 9d4d176013 Fix forecastTime to use API metadata instead of current time
- Use metadata.forecastTime from API response instead of endTime in fetchHistoricalFrames
- Ensures forecast time displays correctly in user's browser timezone
- Fixes issue where forecast time was showing incorrect timezone
2025-12-23 21:03:33 +10:00

58 lines
1.8 KiB
YAML

services:
# BOM Local Service - provides radar data (using pre-built image)
bom-local-service:
image: ghcr.io/alexhopeoconnor/bom-local-service:latest
container_name: bom-card-test-service
ports:
- "8082:8080"
volumes:
# Persist cache between redeploys
- ./test-ha/cache:/app/cache
environment:
# ASP.NET Core configuration
- ASPNETCORE_ENVIRONMENT=Production
- ASPNETCORE_URLS=http://+:8080
# Virtual display for non-headless browser
- DISPLAY=:99
# CORS - allow requests from HA test instance (both container name and localhost)
- CORS__ALLOWEDORIGINS=http://homeassistant:8123,http://localhost:8124,http://127.0.0.1:8124
- CORS__ALLOWEDMETHODS=GET,POST,OPTIONS
- CORS__ALLOWEDHEADERS=*
- CORS__ALLOWCREDENTIALS=false
# Application configuration
- CACHEDIRECTORY=/app/cache
- CACHERETENTIONHOURS=24
- TIMEZONE=Australia/Sydney
# Debug output enabled by default for test environment
- DEBUG__ENABLED=true
- DEBUG__WAITMS=2000
shm_size: '1gb'
ipc: host
restart: unless-stopped
networks:
- bom-test-network
# Home Assistant test instance
# HA runs as root (default) - we fix file permissions after it creates files
homeassistant:
container_name: bom-card-test-ha
image: "ghcr.io/home-assistant/home-assistant:stable"
volumes:
# Mount HA config directory
- ./test-ha/config:/config
# Mount the integration
- ./custom_components/bom_local:/config/custom_components/bom_local
environment:
- TZ=Australia/Brisbane
restart: unless-stopped
ports:
- "8124:8123" # Use 8124 to avoid conflicts with main HA instance
depends_on:
- bom-local-service
networks:
- bom-test-network
networks:
bom-test-network:
driver: bridge