fix: change backend port to 3984, fix healthcheck with node http, relax frontend dependency

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Malin
2026-04-16 13:23:54 +02:00
parent b1a870d5b5
commit b3736c15d6
2 changed files with 7 additions and 7 deletions

View File

@@ -10,16 +10,16 @@ services:
environment: environment:
- REPLICATE_API_TOKEN=${REPLICATE_API_TOKEN} - REPLICATE_API_TOKEN=${REPLICATE_API_TOKEN}
- FRONTEND_URL=${FRONTEND_URL:-http://localhost} - FRONTEND_URL=${FRONTEND_URL:-http://localhost}
- PORT=3001 - PORT=3984
volumes: volumes:
# Persist model config across container restarts # Persist model config across container restarts
- iqai-models:/app/data - iqai-models:/app/data
healthcheck: healthcheck:
test: ["CMD", "wget", "-qO-", "http://localhost:3001/api/health"] test: ["CMD", "node", "-e", "require('http').get('http://localhost:3984/api/health', r => process.exit(r.statusCode === 200 ? 0 : 1)).on('error', () => process.exit(1))"]
interval: 30s interval: 15s
timeout: 10s timeout: 10s
retries: 3 retries: 5
start_period: 10s start_period: 15s
networks: networks:
- iqai-net - iqai-net
@@ -33,7 +33,7 @@ services:
- "${FRONTEND_PORT:-1984}:80" - "${FRONTEND_PORT:-1984}:80"
depends_on: depends_on:
backend: backend:
condition: service_healthy condition: service_started
networks: networks:
- iqai-net - iqai-net

View File

@@ -11,7 +11,7 @@ server {
# Proxy /api requests to backend # Proxy /api requests to backend
location /api { location /api {
proxy_pass http://backend:3001; proxy_pass http://backend:3984;
proxy_http_version 1.1; proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade; proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade'; proxy_set_header Connection 'upgrade';