This repository has been archived on 2026-05-24. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
app/docker-compose.yml
T
groombook-paperclip[bot] 820a5240d1 feat: Docker self-hosting setup
- Fix Dockerfiles to copy pnpm-lock.yaml (frozen-lockfile compliance)
- Add migrate target to API Dockerfile using builder stage
- Add migrate service to docker-compose that runs before API starts
- Add AUTH_DISABLED env var bypass to auth middleware for dev/Docker
- Proxy /api/ from nginx to API container (no CORS needed)
- Include initial Drizzle migration (0000_colossal_colossus.sql)
- Add .env.example with all configurable variables
- Update README with Docker self-hosting instructions

Closes #7

Co-authored-by: Groom Book CTO <cto@groombook.app>
Co-authored-by: Paperclip <noreply@paperclip.ing>
2026-03-17 18:50:07 +00:00

58 lines
1.2 KiB
YAML

services:
postgres:
image: postgres:16-alpine
environment:
POSTGRES_DB: groombook
POSTGRES_USER: groombook
POSTGRES_PASSWORD: groombook
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U groombook"]
interval: 5s
timeout: 5s
retries: 5
migrate:
build:
context: .
dockerfile: apps/api/Dockerfile
target: migrate
environment:
DATABASE_URL: postgres://groombook:groombook@postgres:5432/groombook
depends_on:
postgres:
condition: service_healthy
restart: "no"
api:
build:
context: .
dockerfile: apps/api/Dockerfile
ports:
- "3000:3000"
environment:
DATABASE_URL: postgres://groombook:groombook@postgres:5432/groombook
AUTH_DISABLED: "true"
CORS_ORIGIN: http://localhost:8080
PORT: "3000"
depends_on:
postgres:
condition: service_healthy
migrate:
condition: service_completed_successfully
web:
build:
context: .
dockerfile: apps/web/Dockerfile
ports:
- "8080:80"
depends_on:
- api
volumes:
postgres_data: