not working shit

This commit is contained in:
2023-11-12 22:43:47 +03:00
commit 9f76abcfc4
10 changed files with 410 additions and 0 deletions

28
docker-compose.yml Normal file
View File

@ -0,0 +1,28 @@
services:
postgres:
image: postgres:15.1
volumes:
- ./postgres_data:/var/lib/postgresql/data/:rw
environment:
POSTGRES_USER: user
POSTGRES_PASSWORD: password
POSTGRES_DB: db
healthcheck:
test: ["CMD-SHELL", "pg_isready -d db --user user"]
interval: 2s
timeout: 2s
retries: 5
bot:
build:
context: bot
environment:
DIALECT: postgresql
DRIVER: psycopg2
USER: user
PASSWORD: password
DB_NAME: db
HOST: postgres
PORT: 5432
depends_on:
postgres:
condition: service_healthy