27d2ab0f0d
v1.0 Phase 1.1 — repo-wide lint/format baseline. - eslint.config.mjs (flat config) lints server, client, shared - .prettierrc.json, .prettierignore, .editorconfig, .nvmrc - Root package.json holds shared devDeps; per-package scripts keep their typecheck + test runners - Fix 7 lint issues surfaced by the baseline run: - TicketDetail.tsx: replace ternary-with-side-effects with if/else - admin/Users.tsx: escape apostrophe in JSX - errorHandler.ts: typed err as unknown with ErrorLike refinement - users.ts: Prisma.UserUpdateInput instead of Record<string, any> - seed.ts: drop unused goddard binding - Run prettier across tracked sources for a clean formatting baseline
55 lines
1.2 KiB
YAML
55 lines
1.2 KiB
YAML
# TicketingSystem — Production
|
|
# Copy this file + .env to your server, then:
|
|
# docker compose pull && docker compose up -d
|
|
# First deploy only:
|
|
# docker compose exec server npm run db:seed
|
|
|
|
services:
|
|
postgres:
|
|
image: postgres:16-alpine
|
|
restart: unless-stopped
|
|
environment:
|
|
POSTGRES_DB: ticketing
|
|
POSTGRES_USER: postgres
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ['CMD-SHELL', 'pg_isready -U postgres']
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
networks:
|
|
- internal
|
|
|
|
server:
|
|
image: ${REGISTRY}/josh/ticketing-server:${TAG:-latest}
|
|
restart: unless-stopped
|
|
environment:
|
|
DATABASE_URL: postgresql://postgres:${POSTGRES_PASSWORD}@postgres:5432/ticketing
|
|
JWT_SECRET: ${JWT_SECRET}
|
|
CLIENT_URL: ${CLIENT_URL}
|
|
PORT: 3000
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
networks:
|
|
- internal
|
|
|
|
client:
|
|
image: ${REGISTRY}/josh/ticketing-client:${TAG:-latest}
|
|
restart: unless-stopped
|
|
ports:
|
|
- '${PORT:-3080}:80'
|
|
depends_on:
|
|
- server
|
|
networks:
|
|
- internal
|
|
|
|
networks:
|
|
internal:
|
|
driver: bridge
|
|
|
|
volumes:
|
|
postgres_data:
|