# Yote-In-Vest behind Traefik v3 + Authentik # - Dashboard: https://${BOT_DOMAIN} -> requires Authentik login (authentik@docker) # - Webhook: https://${BOT_DOMAIN}/webhook -> open for TradingView, protected by WEBHOOK_SECRET # Requires the external `proxy` network. services: yote-in-vest: build: . pull_policy: build container_name: yote-in-vest restart: unless-stopped environment: DB_PATH: /data/bot.db WEBHOOK_SECRET: ${WEBHOOK_SECRET:?set WEBHOOK_SECRET} DEMO_MODE: "${DEMO_MODE:-true}" DEMO_DATA: "${DEMO_DATA:-real}" DEMO_INTERVAL: "${DEMO_INTERVAL:-1h}" DEMO_POLL_SECONDS: "${DEMO_POLL_SECONDS:-900}" NEWS_SOURCES: "${NEWS_SOURCES:-google,ecb,fed,finnhub}" FINNHUB_API_KEY: "${FINNHUB_API_KEY:-}" DEEPSEEK_API_KEY: "${DEEPSEEK_API_KEY:-}" DEEPSEEK_MODEL: "${DEEPSEEK_MODEL:-deepseek-chat}" ALPACA_API_KEY: "${ALPACA_API_KEY:-}" ALPACA_SECRET_KEY: "${ALPACA_SECRET_KEY:-}" ALPACA_LIVE: "${ALPACA_LIVE:-false}" PAPER_START_CASH: "${PAPER_START_CASH:-10000}" MAX_POSITION_PCT: "${MAX_POSITION_PCT:-0.10}" MAX_ORDER_EUR: "${MAX_ORDER_EUR:-50}" EUR_USD_RATE: "${EUR_USD_RATE:-1.10}" EUR_GBP_RATE: "${EUR_GBP_RATE:-0.87}" ENFORCE_MARKET_HOURS: "${ENFORCE_MARKET_HOURS:-true}" MAX_OPEN_POSITIONS: "${MAX_OPEN_POSITIONS:-4}" DAILY_LOSS_LIMIT_PCT: "${DAILY_LOSS_LIMIT_PCT:-0.03}" VETO_CONFIDENCE: "${VETO_CONFIDENCE:-0.6}" BLOCK_BUYS_IF_FILTER_FAILS: "${BLOCK_BUYS_IF_FILTER_FAILS:-true}" US_AFTER_HOURS: "${US_AFTER_HOURS:-skip}" volumes: - yote-in-vest-data:/data networks: - proxy labels: traefik.enable: "true" traefik.docker.network: proxy traefik.http.services.yote-in-vest.loadbalancer.server.port: "8000" # Webhook: no Authentik (TradingView can't log in); WEBHOOK_SECRET protects it traefik.http.routers.yote-in-vest-webhook.rule: Host(`${BOT_DOMAIN:-yoteinvest.dv3.app}`) && Path(`/webhook`) traefik.http.routers.yote-in-vest-webhook.entrypoints: websecure traefik.http.routers.yote-in-vest-webhook.tls.certresolver: letsencrypt traefik.http.routers.yote-in-vest-webhook.priority: "100" traefik.http.routers.yote-in-vest-webhook.service: yote-in-vest # Optional: only accept webhooks from TradingView's IPs # traefik.http.middlewares.yote-in-vest-tv-ips.ipallowlist.sourcerange: 52.89.214.238,34.212.75.30,54.218.53.128,52.32.178.7 # traefik.http.routers.yote-in-vest-webhook.middlewares: yote-in-vest-tv-ips # Dashboard: everything else, behind Authentik traefik.http.routers.yote-in-vest.rule: Host(`${BOT_DOMAIN:-yoteinvest.dv3.app}`) traefik.http.routers.yote-in-vest.entrypoints: websecure traefik.http.routers.yote-in-vest.tls.certresolver: letsencrypt traefik.http.routers.yote-in-vest.priority: "10" traefik.http.routers.yote-in-vest.service: yote-in-vest traefik.http.routers.yote-in-vest.middlewares: authentik@docker,secure-headers@docker volumes: yote-in-vest-data: # Set DATA_VOLUME to the existing volume name to keep your current data name: ${DATA_VOLUME:-yote-in-vest-data} networks: proxy: external: true