2026-01-11 15:30:43 +00:00
version : '3.8'
2026-01-03 21:59:48 +00:00
2026-01-11 15:30:43 +00:00
services :
# ============================================================================
# INFRASTRUCTURE SERVICES
# ============================================================================
2026-01-03 21:59:48 +00:00
postgres :
image : postgres:16-alpine
2026-01-11 15:30:43 +00:00
container_name : veza_postgres
2026-01-03 21:59:48 +00:00
restart : unless-stopped
environment :
2026-01-11 15:30:43 +00:00
POSTGRES_USER : ${DB_USER:-veza}
2026-02-11 21:43:09 +00:00
POSTGRES_PASSWORD : ${DB_PASS:?DB_PASS must be set for production}
2026-01-11 15:30:43 +00:00
POSTGRES_DB : ${DB_NAME:-veza}
2026-01-03 21:59:48 +00:00
volumes :
2026-01-11 15:30:43 +00:00
- postgres_data:/var/lib/postgresql/data
2026-01-03 21:59:48 +00:00
healthcheck :
2026-01-11 15:30:43 +00:00
test : [ "CMD-SHELL" , "pg_isready -U ${DB_USER:-veza}" ]
interval : 5s
2026-01-03 21:59:48 +00:00
timeout : 5s
retries : 5
2026-01-11 15:30:43 +00:00
networks :
- veza-network
deploy :
resources :
limits :
cpus : '0.50'
memory : 256M
2026-01-03 21:59:48 +00:00
redis :
image : redis:7-alpine
2026-01-11 15:30:43 +00:00
container_name : veza_redis
2026-01-03 21:59:48 +00:00
restart : unless-stopped
2026-02-22 16:24:12 +00:00
command : [ "redis-server" , "--requirepass" , "${REDIS_PASSWORD:?REDIS_PASSWORD must be set for production}" , "--appendonly" , "yes" ]
2026-01-03 21:59:48 +00:00
volumes :
2026-01-11 15:30:43 +00:00
- redis_data:/data
2026-01-03 21:59:48 +00:00
healthcheck :
2026-02-22 16:24:12 +00:00
test : [ "CMD" , "redis-cli" , "-a" , "${REDIS_PASSWORD}" , "ping" ]
2026-01-11 15:30:43 +00:00
interval : 5s
timeout : 3s
retries : 5
networks :
- veza-network
deploy :
resources :
limits :
cpus : '0.25'
memory : 64M
2026-01-03 21:59:48 +00:00
rabbitmq :
image : rabbitmq:3-management-alpine
2026-01-11 15:30:43 +00:00
container_name : veza_rabbitmq
2026-01-03 21:59:48 +00:00
restart : unless-stopped
environment :
2026-01-11 15:30:43 +00:00
RABBITMQ_DEFAULT_USER : ${DB_USER:-veza}
2026-02-11 21:43:09 +00:00
RABBITMQ_DEFAULT_PASS : ${RABBITMQ_PASS:?RABBITMQ_PASS must be set for production}
2026-01-03 21:59:48 +00:00
volumes :
2026-01-11 15:30:43 +00:00
- rabbitmq_data:/var/lib/rabbitmq
2026-01-03 21:59:48 +00:00
healthcheck :
test : rabbitmq-diagnostics -q ping
2026-01-11 15:30:43 +00:00
interval : 10s
timeout : 10s
retries : 5
networks :
- veza-network
2026-01-03 21:59:48 +00:00
deploy :
resources :
limits :
2026-01-11 15:30:43 +00:00
cpus : '0.50'
memory : 256M
2026-01-03 21:59:48 +00:00
2026-02-18 11:03:14 +00:00
clamav :
image : clamav/clamav:latest
container_name : veza_clamav
restart : unless-stopped
networks :
- veza-network
healthcheck :
test : [ "CMD" , "clamdscan" , "--ping" , "1" ]
interval : 30s
timeout : 10s
retries : 5
start_period : 180s
deploy :
resources :
limits :
cpus : '0.5'
memory : 1G
2026-02-14 20:45:15 +00:00
# ============================================================================
# PAYMENT ROUTER (Hyperswitch)
# ============================================================================
hyperswitch_postgres :
image : postgres:16-alpine
container_name : veza_hyperswitch_postgres
restart : unless-stopped
environment :
POSTGRES_USER : ${HYPERSWITCH_DB_USER:-hyperswitch}
POSTGRES_PASSWORD : ${HYPERSWITCH_DB_PASS:?HYPERSWITCH_DB_PASS must be set for production}
POSTGRES_DB : ${HYPERSWITCH_DB_NAME:-hyperswitch}
volumes :
- hyperswitch_postgres_data:/var/lib/postgresql/data
healthcheck :
test : [ "CMD-SHELL" , "pg_isready -U ${HYPERSWITCH_DB_USER:-hyperswitch}" ]
interval : 5s
timeout : 5s
retries : 5
networks :
- veza-network
deploy :
resources :
limits :
cpus : "0.25"
memory : 128M
hyperswitch :
image : juspaydotin/hyperswitch-router:2025.01.21.0-standalone
container_name : veza_hyperswitch
restart : unless-stopped
environment :
DATABASE_URL : postgresql://${HYPERSWITCH_DB_USER:-hyperswitch}:${HYPERSWITCH_DB_PASS:?HYPERSWITCH_DB_PASS must be set}@hyperswitch_postgres:5432/${HYPERSWITCH_DB_NAME:-hyperswitch}?sslmode=require
2026-02-22 16:24:12 +00:00
REDIS_URL : redis://:${REDIS_PASSWORD}@redis:6379
2026-02-14 20:45:15 +00:00
depends_on :
hyperswitch_postgres :
condition : service_healthy
redis :
condition : service_healthy
networks :
- veza-network
healthcheck :
test : [ "CMD" , "wget" , "--quiet" , "--tries=1" , "--spider" , "http://localhost:8080/health" ]
interval : 10s
timeout : 5s
retries : 3
deploy :
resources :
limits :
cpus : "0.5"
memory : 256M
2026-01-11 15:30:43 +00:00
# ============================================================================
# APPLICATION SERVICES
# ============================================================================
backend-api :
2026-01-03 21:59:48 +00:00
build :
context : ./veza-backend-api
dockerfile : Dockerfile.production
2026-01-11 15:30:43 +00:00
image : veza-backend-api:latest
container_name : veza_backend_api
2026-01-03 21:59:48 +00:00
restart : unless-stopped
environment :
- APP_ENV=production
2026-02-11 21:43:09 +00:00
- DATABASE_URL=postgres://${DB_USER:-veza}:${DB_PASS:?DB_PASS must be set}@postgres:5432/${DB_NAME:-veza}?sslmode=require
2026-02-22 16:24:12 +00:00
- REDIS_URL=redis://:${REDIS_PASSWORD:?REDIS_PASSWORD must be set}@redis:6379
2026-02-11 21:43:09 +00:00
- AMQP_URL=amqp://${DB_USER:-veza}:${RABBITMQ_PASS:?RABBITMQ_PASS must be set}@rabbitmq:5672
- JWT_SECRET=${JWT_SECRET:?JWT_SECRET must be set for production}
2026-01-11 15:30:43 +00:00
- COOKIE_SECURE=true
- COOKIE_SAME_SITE=strict
- COOKIE_HTTP_ONLY=true
2026-02-11 21:18:57 +00:00
- CORS_ALLOWED_ORIGINS=${CORS_ORIGINS:-http://veza.fr}
2026-02-14 20:45:15 +00:00
- HYPERSWITCH_URL=http://hyperswitch:8080
- HYPERSWITCH_API_KEY=${HYPERSWITCH_API_KEY:-}
- HYPERSWITCH_WEBHOOK_SECRET=${HYPERSWITCH_WEBHOOK_SECRET:-}
- HYPERSWITCH_ENABLED=${HYPERSWITCH_ENABLED:-false}
- CHECKOUT_SUCCESS_URL=${CHECKOUT_SUCCESS_URL:-https://veza.fr/purchases}
2026-02-18 11:03:14 +00:00
- ENABLE_CLAMAV=true
- CLAMAV_REQUIRED=true
- CLAMAV_ADDRESS=clamav:3310
feat(v0.501): Sprint 1 -- infrastructure foundations
- Add MinIO S3-compatible storage to docker-compose (dev, staging, prod)
- Create migrations 103-108 (waveform_url, user_folders, user_files,
user_storage_quotas, gear_items.is_public, gear_images)
- Add Go models: UserFile, UserFolder, StorageQuota, GearImage
- Add WaveformURL to Track model, IsPublic + GearImages to GearItem model
2026-02-22 17:10:25 +00:00
- AWS_S3_ENDPOINT=http://minio:9000
- AWS_S3_BUCKET=veza-files
- AWS_ACCESS_KEY_ID=${S3_ACCESS_KEY:?S3_ACCESS_KEY must be set}
- AWS_SECRET_ACCESS_KEY=${S3_SECRET_KEY:?S3_SECRET_KEY must be set}
- AWS_REGION=${AWS_REGION:-us-east-1}
2026-01-03 21:59:48 +00:00
depends_on :
postgres :
condition : service_healthy
redis :
condition : service_healthy
rabbitmq :
condition : service_healthy
2026-02-18 11:03:14 +00:00
clamav :
condition : service_started
2026-01-11 15:30:43 +00:00
networks :
- veza-network
healthcheck :
test : [ "CMD" , "wget" , "--quiet" , "--tries=1" , "--spider" , "http://localhost:8080/api/v1/health" ]
interval : 10s
timeout : 5s
retries : 3
2026-01-03 21:59:48 +00:00
feat(chat): Sprint 4 -- Docker cleanup, frontend migration to Go WS
- Remove Rust chat-server from docker-compose.yml, staging.yml, prod.yml
- Remove VITE_WS_URL from docker frontend env vars (auto-derived from API_URL)
- Update env.ts: derive WS_URL from API_URL (/api/v1/ws) when not explicitly set
- Remove 127.0.0.1:8081 dev hack from useChat.ts
- Add missing types: EditMessage, DeleteMessage, FetchHistory, SearchMessages,
SyncMessages, MessageEdited, MessageDeleted, SearchResults, SyncChunk
- Update MSW chat/token handler to return ws_url: /api/v1/ws
- Update .env.example and .env.storybook
2026-02-22 19:46:58 +00:00
# Chat Server removed in v0.502 -- chat is now handled by backend-api WebSocket at /api/v1/ws
2026-01-03 21:59:48 +00:00
2026-01-11 15:30:43 +00:00
stream-server :
2026-01-03 21:59:48 +00:00
build :
context : ./veza-stream-server
dockerfile : Dockerfile.production
2026-01-11 15:30:43 +00:00
image : veza-stream-server:latest
container_name : veza_stream_server
2026-01-03 21:59:48 +00:00
restart : unless-stopped
environment :
2026-02-11 21:43:09 +00:00
- DATABASE_URL=postgres://${DB_USER:-veza}:${DB_PASS:?DB_PASS must be set}@postgres:5432/${DB_NAME:-veza}?sslmode=require
2026-02-22 16:24:12 +00:00
- REDIS_URL=redis://:${REDIS_PASSWORD:?REDIS_PASSWORD must be set}@redis:6379
2026-02-22 16:28:37 +00:00
- JWT_SECRET=${JWT_SECRET:?JWT_SECRET must be set}
2026-01-11 15:30:43 +00:00
- PORT=3001
2026-01-03 21:59:48 +00:00
depends_on :
postgres :
condition : service_healthy
2026-01-11 15:30:43 +00:00
redis :
2026-01-03 21:59:48 +00:00
condition : service_healthy
2026-01-11 15:30:43 +00:00
networks :
- veza-network
healthcheck :
test : [ "CMD" , "wget" , "--quiet" , "--tries=1" , "--spider" , "http://localhost:3001/health" ]
interval : 10s
timeout : 5s
retries : 3
2026-01-03 21:59:48 +00:00
feat(v0.501): Sprint 1 -- infrastructure foundations
- Add MinIO S3-compatible storage to docker-compose (dev, staging, prod)
- Create migrations 103-108 (waveform_url, user_folders, user_files,
user_storage_quotas, gear_items.is_public, gear_images)
- Add Go models: UserFile, UserFolder, StorageQuota, GearImage
- Add WaveformURL to Track model, IsPublic + GearImages to GearItem model
2026-02-22 17:10:25 +00:00
minio :
image : minio/minio:latest
container_name : veza_minio
restart : unless-stopped
command : server /data --console-address ":9001"
environment :
MINIO_ROOT_USER : ${S3_ACCESS_KEY:?S3_ACCESS_KEY must be set}
MINIO_ROOT_PASSWORD : ${S3_SECRET_KEY:?S3_SECRET_KEY must be set}
volumes :
- minio_data:/data
networks :
- veza-network
healthcheck :
test : [ "CMD" , "mc" , "ready" , "local" ]
interval : 10s
timeout : 5s
retries : 3
minio-init :
image : minio/mc:latest
depends_on :
minio :
condition : service_healthy
entrypoint : >
/bin/sh -c "
mc alias set veza http://minio:9000 $${MINIO_ROOT_USER} $${MINIO_ROOT_PASSWORD};
mc mb --ignore-existing veza/veza-files;
exit 0;
"
environment :
MINIO_ROOT_USER : ${S3_ACCESS_KEY:?S3_ACCESS_KEY must be set}
MINIO_ROOT_PASSWORD : ${S3_SECRET_KEY:?S3_SECRET_KEY must be set}
networks :
- veza-network
2026-01-11 15:30:43 +00:00
web :
2026-01-03 21:59:48 +00:00
build :
context : ./apps/web
dockerfile : Dockerfile.production
2026-01-11 15:30:43 +00:00
image : veza-web:latest
container_name : veza_web
2026-01-03 21:59:48 +00:00
restart : unless-stopped
environment :
2026-01-11 15:30:43 +00:00
- VITE_API_URL=http://haproxy/api/v1
- VITE_STREAM_URL=ws://haproxy/stream
- VITE_UPLOAD_URL=http://haproxy/api/v1/uploads
2026-01-03 21:59:48 +00:00
depends_on :
2026-01-11 15:30:43 +00:00
- backend-api
- stream-server
networks :
- veza-network
healthcheck :
test : [ "CMD" , "wget" , "--quiet" , "--tries=1" , "--spider" , "http://localhost:5173" ]
interval : 10s
timeout : 5s
retries : 3
2026-01-03 21:59:48 +00:00
2026-01-11 15:30:43 +00:00
# ============================================================================
# REVERSE PROXY - HAProxy
# ============================================================================
haproxy :
image : haproxy:2.8-alpine
container_name : veza_haproxy
restart : unless-stopped
2026-02-15 14:58:51 +00:00
deploy :
resources :
limits :
cpus : '0.5'
memory : 128M
2026-01-11 15:30:43 +00:00
ports :
- "${PORT_HAPROXY:-80}:80"
- "443:443"
volumes :
- ./config/haproxy/haproxy.cfg:/usr/local/etc/haproxy/haproxy.cfg:ro
2026-02-15 14:58:51 +00:00
- ./config/ssl:/etc/ssl/veza:ro
2026-01-11 15:30:43 +00:00
depends_on :
- backend-api
- stream-server
- web
networks :
- veza-network
healthcheck :
test : [ "CMD" , "haproxy" , "-c" , "-f" , "/usr/local/etc/haproxy/haproxy.cfg" ]
interval : 10s
timeout : 5s
retries : 3
2026-01-03 21:59:48 +00:00
2026-01-11 15:30:43 +00:00
networks :
veza-network :
driver : bridge
ipam :
config :
- subnet : 172.20 .0 .0 /16
2026-01-03 21:59:48 +00:00
2026-01-11 15:30:43 +00:00
volumes :
postgres_data :
redis_data :
rabbitmq_data :
2026-02-14 20:45:15 +00:00
hyperswitch_postgres_data :
feat(v0.501): Sprint 1 -- infrastructure foundations
- Add MinIO S3-compatible storage to docker-compose (dev, staging, prod)
- Create migrations 103-108 (waveform_url, user_folders, user_files,
user_storage_quotas, gear_items.is_public, gear_images)
- Add Go models: UserFile, UserFolder, StorageQuota, GearImage
- Add WaveformURL to Track model, IsPublic + GearImages to GearItem model
2026-02-22 17:10:25 +00:00
minio_data :