Files
planner.sori.studio/docker-compose.yml

49 lines
985 B
YAML

services:
postgres:
image: postgres:16-alpine
container_name: ten-minute-postgres
env_file:
- ./.env
volumes:
- postgres_data:/var/lib/postgresql/data
ports:
- "45432:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U \"$${POSTGRES_USER}\" -d \"$${POSTGRES_DB}\""]
interval: 10s
timeout: 5s
retries: 10
restart: unless-stopped
backend:
build:
context: ./backend
container_name: ten-minute-backend
env_file:
- ./.env
environment:
PORT: 3001
CORS_ORIGIN: http://localhost:48081
SESSION_TTL_DAYS: 30
depends_on:
postgres:
condition: service_healthy
expose:
- "3001"
restart: unless-stopped
frontend:
build:
context: .
args:
VITE_API_BASE_URL: /api
container_name: ten-minute-frontend
depends_on:
- backend
ports:
- "48081:80"
restart: unless-stopped
volumes:
postgres_data: