Files
open-school/docker-compose.yml
2026-04-05 10:22:09 +02:00

52 lines
1.1 KiB
YAML

services:
postgres:
image: postgres:16-alpine
environment:
POSTGRES_DB: tutor
POSTGRES_USER: tutor
POSTGRES_PASSWORD: tutor
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
redis:
image: redis:7-alpine
ports:
- "6379:6379"
backend:
build: ./backend
environment:
OPENAI_API_KEY: ${OPENAI_API_KEY}
DATABASE_URL: postgresql+psycopg2://tutor:tutor@postgres:5432/tutor
REDIS_URL: redis://redis:6379/0
APP_ENV: development
FRONTEND_ORIGIN: http://localhost:3000
ports:
- "8000:8000"
depends_on:
- postgres
- redis
volumes:
- ./backend:/app
frontend:
build: ./frontend
environment:
VITE_ALLOWED_HOST: prof.open-squared.tech
VITE_DEV_API_PROXY_TARGET: http://backend:8000
VITE_HMR_HOST: prof.open-squared.tech
VITE_HMR_PROTOCOL: wss
VITE_HMR_CLIENT_PORT: 443
ports:
- "3000:3000"
depends_on:
- backend
volumes:
- ./frontend:/app
- /app/node_modules
volumes:
postgres_data: