avoid coolify host-port collisions by exposing app port internally

This commit is contained in:
2026-02-24 11:00:13 -05:00
parent 3e72f38928
commit bb01311a8a
4 changed files with 10 additions and 3 deletions

View File

@@ -1,5 +1,7 @@
# Optional API override. Leave empty to use same-origin internal API routes.
NEXT_PUBLIC_API_URL=
# Local docker host port (used by docker-compose.override.yml)
APP_PORT=3000
# OpenClaw / ZeroClaw (OpenAI-compatible)

View File

@@ -33,7 +33,8 @@ cp .env.example .env
docker compose up --build -d
```
Default app URL: `http://localhost:3000` (override with `APP_PORT` in `.env`).
For local Docker, host port mapping comes from `docker-compose.override.yml` (default `http://localhost:3000`, configurable via `APP_PORT`).
For Coolify/remote Docker Compose, only container port `3000` is exposed internally (no fixed host port bind), avoiding host port collisions.
Runtime data persists in the `app_data` volume (`/app/data` in container).
## Environment

View File

@@ -0,0 +1,4 @@
services:
app:
ports:
- '${APP_PORT:-3000}:3000'

View File

@@ -22,8 +22,8 @@ services:
interval: 30s
timeout: 10s
retries: 3
ports:
- '${APP_PORT:-3000}:3000'
expose:
- "3000"
volumes:
- app_data:/app/data