From 175c368cfdfbb6119a3122c24beb5e746b266b5d Mon Sep 17 00:00:00 2001 From: hobokenchicken Date: Tue, 21 Apr 2026 13:30:59 -0400 Subject: [PATCH] fix(docker): align backend port with Caddy reverse proxy Caddy routes /api/* to port 3002 but docker-compose exposed backend on 3001. Changed backend port, healthcheck, and frontend fallback to 3002 for consistency. --- docker-compose.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 512fd09..241ee7b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -39,7 +39,7 @@ services: dockerfile: backend/Dockerfile container_name: coop-backend healthcheck: - test: ["CMD-SHELL", "wget -qO- http://localhost:3001/health || exit 1"] + test: ["CMD-SHELL", "wget -qO- http://localhost:3002/health || exit 1"] interval: 5s timeout: 5s retries: 5 @@ -47,7 +47,7 @@ services: - NODE_ENV=production - DATABASE_URL=postgresql://coop:coop_password@postgres:5432/coop_credits?schema=public - REDIS_URL=redis://redis:6379 - - PORT=3001 + - PORT=3002 - JWT_SECRET=${JWT_SECRET} - SOLANA_RPC_URL=${SOLANA_RPC_URL:-https://api.devnet.solana.com} - SOLANA_PROGRAM_ID=${SOLANA_PROGRAM_ID} @@ -61,7 +61,7 @@ services: - OVERSEER_API_KEY=${OVERSEER_API_KEY} - ENCRYPTION_KEY=${ENCRYPTION_KEY} ports: - - "3001:3001" # Exposed on all interfaces + - "3002:3002" # Exposed on all interfaces depends_on: postgres: condition: service_healthy @@ -76,13 +76,13 @@ services: context: . dockerfile: frontend/Dockerfile args: - - NEXT_PUBLIC_API_URL=${API_URL:-http://localhost:3001} + - NEXT_PUBLIC_API_URL=${API_URL:-http://localhost:3002} - NEXT_PUBLIC_SOLANA_NETWORK=devnet - NEXT_PUBLIC_SOLANA_RPC_URL=https://api.devnet.solana.com container_name: coop-frontend environment: - NODE_ENV=production - - NEXT_PUBLIC_API_URL=${API_URL:-http://localhost:3001} + - NEXT_PUBLIC_API_URL=${API_URL:-http://localhost:3002} - NEXT_PUBLIC_SOLANA_NETWORK=devnet - NEXT_PUBLIC_SOLANA_RPC_URL=https://api.devnet.solana.com ports: