29 lines
609 B
YAML
29 lines
609 B
YAML
services:
|
|
app:
|
|
build:
|
|
context: .
|
|
dockerfile: app/Dockerfile
|
|
command: uvicorn app.main:app --host 0.0.0.0 --port 8000
|
|
env_file:
|
|
- .env
|
|
environment:
|
|
DATABASE_URL: postgresql+asyncpg://postgres:postgres@postgres:5432/test_task_crm
|
|
ports:
|
|
- "8000:8000"
|
|
depends_on:
|
|
- postgres
|
|
|
|
postgres:
|
|
image: postgres:16-alpine
|
|
environment:
|
|
POSTGRES_DB: test_task_crm
|
|
POSTGRES_USER: postgres
|
|
POSTGRES_PASSWORD: postgres
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
ports:
|
|
- "5432:5432"
|
|
|
|
volumes:
|
|
postgres_data:
|