From 2b8854130a1d0989b1ca805e4628c7d5e551bfbc Mon Sep 17 00:00:00 2001 From: BetterHuman Date: Wed, 6 May 2026 04:18:44 +0000 Subject: [PATCH] fix: serve on port 80 to match Coolify/Traefik routing config --- Dockerfile | 2 +- backend/src/index.ts | 2 +- start.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 221dd1c8..4914e6fb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -36,6 +36,6 @@ COPY --from=frontend-build /app/frontend/dist ./public COPY start.sh ./ RUN chmod +x start.sh -EXPOSE 3000 +EXPOSE 80 CMD ["./start.sh"] diff --git a/backend/src/index.ts b/backend/src/index.ts index 84202021..19002580 100644 --- a/backend/src/index.ts +++ b/backend/src/index.ts @@ -22,7 +22,7 @@ import settingsRouter from './routes/settings'; import notificationsRouter from './routes/notifications'; const app = express(); -const PORT = parseInt(process.env.PORT || '3000', 10); +const PORT = parseInt(process.env.PORT || '80', 10); // Trust Coolify/Traefik reverse proxy app.set('trust proxy', 1); diff --git a/start.sh b/start.sh index 42d33b9e..dee071b8 100644 --- a/start.sh +++ b/start.sh @@ -179,5 +179,5 @@ async function seed() { seed(); " 2>/dev/null || echo "[start] Seed warning (continuing)" -echo "[start] Starting Node.js backend on port 3000..." +echo "[start] Starting Node.js backend on port ${PORT:-80}..." exec node dist/index.js