version: '3.8' services: postgres: image: postgres:14-alpine restart: always command: postgres -c listen_addresses='*' container_name: nowplaying-db volumes: - ./db_data/postgres:/var/lib/postgresql/data env_file: - .env healthcheck: test: ["CMD-SHELL", "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"] interval: 10s timeout: 5s retries: 5 start_period: 5s networks: - internal_network telegram-bot-api: image: ghcr.io/es3n1n/telegram-bot-api:latest restart: unless-stopped container_name: nowplaying-bot-api env_file: - .env volumes: - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro - tg_data:/var/lib/telegram-bot-api networks: - default_network - internal_network bot-api-janitor: image: bot-api-janitor:latest restart: unless-stopped container_name: nowplaying-bot-api-janitor build: botapi_janitor volumes: - tg_data:/var/lib/telegram-bot-api environment: - TZ=$(cat /etc/timezone) nowplaying: image: nowplaying-bot:latest restart: unless-stopped container_name: nowplaying-bot build: . ports: - "31337:1337" depends_on: postgres: condition: service_started telegram-bot-api: condition: service_started env_file: - .env networks: - internal_network - udownloader_network tmpfs: - /tmp nowplaying-grpc: image: nowplaying-grpc:latest restart: unless-stopped container_name: nowplaying-grpc build: ynison_proxy networks: - internal_network - default_network networks: default_network: internal_network: driver: bridge internal: true udownloader_network: name: udownloader external: true volumes: # Not a directory to avoid errors due to : in filenames on windows tg_data: name: "nowplaying_tg_data"