.env.example 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. # Broad-Announce M0 env defaults. Copy to .env if you want docker
  2. # compose to pick them up; otherwise the compose file's inline
  3. # values are used.
  4. BA_ENV=dev
  5. BA_LOG_LEVEL=info
  6. # HTTP addrs
  7. BA_INGESTD_HTTP_ADDR=:8800
  8. BA_ROUTERD_HTTP_ADDR=:8801
  9. BA_DELIVERD_HTTP_ADDR=:8802
  10. BA_ADMIND_HTTP_ADDR=:8803
  11. # Data tier
  12. BA_NATS_URL=nats://localhost:4222
  13. BA_REDIS_URL=redis://localhost:6379/0
  14. BA_POSTGRES_DSN=postgres://ba:ba@localhost:5432/ba?sslmode=disable
  15. # Ingestd source protection defaults (SPEC §22)
  16. BA_INGESTD_MAX_PAYLOAD_BYTES=262144
  17. BA_INGESTD_RATE_LIMIT_PER_SOURCE=100
  18. BA_INGESTD_RATE_LIMIT_PER_COMPANY=10000
  19. BA_INGESTD_MAX_CONCURRENT_PER_IP=64
  20. BA_INGESTD_DEDUPE_TTL_SECONDS=300
  21. BA_INGESTD_QUARANTINE_HITS_THRESHOLD=100
  22. BA_INGESTD_QUARANTINE_WINDOW_SECONDS=60
  23. BA_INGESTD_QUARANTINE_DURATION_SECONDS=300
  24. # M0 source registry (env-only; M2 swaps for DB)
  25. # Format: comma-separated company:source:secret triples
  26. BA_INGESTD_SOURCES=acme-001:prom-prod:s3cret-acme,globex-002:grafana:s3cret-globex
  27. # M4 MQTT subscriber (ingestd).
  28. # - MQTT_USERNAME/PASSWORD authenticate the subscriber with EMQX
  29. # using the built-in-db row "ingestd" / "ingestd-broker-only".
  30. # - MQTT_SUBSCRIBE is the topic pattern the subscriber joins.
  31. # The + wildcards are the EMQX single-level wildcard; ba/+/+/incoming
  32. # matches every (company, source) pair.
  33. # - Set BA_INGESTD_MQTT_BROKER to "" to disable the MQTT path entirely.
  34. BA_INGESTD_MQTT_BROKER=tcp://emqx:1883
  35. BA_INGESTD_MQTT_USERNAME=ingestd
  36. BA_INGESTD_MQTT_PASSWORD=ingestd-broker-only
  37. BA_INGESTD_MQTT_SUBSCRIBE=ba/+/+/incoming
  38. # Optional override; default is "ingestd-mqtt-<hostname>".
  39. # BA_INGESTD_MQTT_CLIENT_ID=ingestd-mqtt-1
  40. # Shutdown
  41. BA_SHUTDOWN_GRACE_SEC=15