28 lines
802 B
YAML
28 lines
802 B
YAML
services:
|
|
bot:
|
|
build: .
|
|
depends_on:
|
|
db:
|
|
condition: service_healthy
|
|
environment:
|
|
- DATABASE_URL=postgres://uphold:uphold_password@db:5432/uphold_alerts
|
|
- PAIRS=${PAIRS:-BTC-USD,ETH-USD}
|
|
- INTERVAL=${INTERVAL:-5000}
|
|
- THRESHOLD=${THRESHOLD:-0.01}
|
|
command: ["--pairs", "${PAIRS:-BTC-USD,ETH-USD}", "--interval", "${INTERVAL:-5000}", "--threshold", "${THRESHOLD:-0.01}"]
|
|
db:
|
|
image: docker.io/postgres:15-alpine
|
|
environment:
|
|
- POSTGRES_USER=uphold
|
|
- POSTGRES_PASSWORD=uphold_password
|
|
- POSTGRES_DB=uphold_alerts
|
|
volumes:
|
|
- pgdata:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U uphold -d uphold_alerts"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
volumes:
|
|
pgdata:
|