Files
nwxraybot/docker-compose.yml

42 lines
800 B
YAML

services:
bot:
image: aboba:latest
deploy:
replicas: 1
restart_policy:
condition: on-failure
networks:
- bot_network
depends_on:
db:
condition: service_healthy
db:
image: postgres:alpine
deploy:
replicas: 1
restart_policy:
condition: on-failure
environment:
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_DB: ${POSTGRES_DB:-postgres}
ports:
- 5432
healthcheck:
test: ["CMD", "pg_isready"]
interval: 10s
timeout: 5s
retries: 10
networks:
- bot_network
volumes:
- postgres_data:/var/lib/postgresql/data
networks:
bot_network:
driver: overlay
volumes:
postgres_data: