Some checks failed
CI Pipeline / changes (push) Has been cancelled
CI Pipeline / core (push) Has been cancelled
CI Pipeline / trading-backend (push) Has been cancelled
CI Pipeline / trading-data-service (push) Has been cancelled
CI Pipeline / trading-frontend (push) Has been cancelled
CI Pipeline / erp-core (push) Has been cancelled
CI Pipeline / erp-mecanicas (push) Has been cancelled
CI Pipeline / gamilit-backend (push) Has been cancelled
CI Pipeline / gamilit-frontend (push) Has been cancelled
94 lines
2.4 KiB
YAML
94 lines
2.4 KiB
YAML
version: '3.8'
|
|
|
|
services:
|
|
data-service:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
container_name: orbiquant-data-service
|
|
restart: unless-stopped
|
|
ports:
|
|
- "${DATA_SERVICE_PORT:-8001}:8001"
|
|
environment:
|
|
# Database
|
|
- DB_HOST=${DB_HOST:-postgres}
|
|
- DB_PORT=${DB_PORT:-5432}
|
|
- DB_NAME=${DB_NAME:-orbiquant_trading}
|
|
- DB_USER=${DB_USER:-orbiquant_user}
|
|
- DB_PASSWORD=${DB_PASSWORD:-orbiquant_dev_2025}
|
|
|
|
# Data Providers
|
|
- POLYGON_API_KEY=${POLYGON_API_KEY:-}
|
|
- POLYGON_TIER=${POLYGON_TIER:-basic}
|
|
- BINANCE_API_KEY=${BINANCE_API_KEY:-}
|
|
- BINANCE_API_SECRET=${BINANCE_API_SECRET:-}
|
|
- BINANCE_TESTNET=${BINANCE_TESTNET:-false}
|
|
|
|
# MetaAPI (MT4/MT5)
|
|
- METAAPI_TOKEN=${METAAPI_TOKEN:-}
|
|
- METAAPI_ACCOUNT_ID=${METAAPI_ACCOUNT_ID:-}
|
|
|
|
# Service Settings
|
|
- SYNC_INTERVAL_MINUTES=${SYNC_INTERVAL_MINUTES:-5}
|
|
- BACKFILL_DAYS=${BACKFILL_DAYS:-30}
|
|
- LOG_LEVEL=${LOG_LEVEL:-INFO}
|
|
|
|
volumes:
|
|
- ./src:/app/src:ro
|
|
- ./logs:/app/logs
|
|
networks:
|
|
- orbiquant-network
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
redis:
|
|
condition: service_started
|
|
healthcheck:
|
|
test: ["CMD", "curl", "-f", "http://localhost:8001/health"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 3
|
|
start_period: 10s
|
|
|
|
postgres:
|
|
image: timescale/timescaledb:latest-pg15
|
|
container_name: orbiquant-timescaledb
|
|
restart: unless-stopped
|
|
ports:
|
|
- "${POSTGRES_PORT:-5432}:5432"
|
|
environment:
|
|
- POSTGRES_USER=${DB_USER:-orbiquant_user}
|
|
- POSTGRES_PASSWORD=${DB_PASSWORD:-orbiquant_dev_2025}
|
|
- POSTGRES_DB=${DB_NAME:-orbiquant_trading}
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
- ./database/init:/docker-entrypoint-initdb.d:ro
|
|
networks:
|
|
- orbiquant-network
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U ${DB_USER:-orbiquant_user} -d ${DB_NAME:-orbiquant_trading}"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
container_name: orbiquant-redis
|
|
restart: unless-stopped
|
|
ports:
|
|
- "${REDIS_PORT:-6379}:6379"
|
|
command: redis-server --appendonly yes
|
|
volumes:
|
|
- redis_data:/data
|
|
networks:
|
|
- orbiquant-network
|
|
|
|
networks:
|
|
orbiquant-network:
|
|
driver: bridge
|
|
name: orbiquant-network
|
|
|
|
volumes:
|
|
postgres_data:
|
|
redis_data:
|