From bc72ecbee76453d6b90fa525d58f01b437a9a144 Mon Sep 17 00:00:00 2001 From: Yash Kuceriya Date: Mon, 23 Feb 2026 17:51:33 -0700 Subject: [PATCH] chore(railway): log PORT in entrypoint, make seed non-fatal, add deploy log troubleshooting Co-authored-by: Cursor --- ENV_KEYS.md | 2 ++ docker/entrypoint.sh | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ENV_KEYS.md b/ENV_KEYS.md index fbc0d1cef..be6a41bbb 100644 --- a/ENV_KEYS.md +++ b/ENV_KEYS.md @@ -43,6 +43,8 @@ Here, **Postgres and Redis are provided by Railway**; you only generate the two **Setup:** In your Railway project, open the **Ghostfolio** service (the one from GitHub) → **Variables** → add each variable. For Postgres and Redis, copy from the addon services. For `ACCESS_TOKEN_SALT` and `JWT_SECRET_KEY`, generate once and paste. +**If healthcheck fails:** Open the Ghostfolio service → **Deployments** → latest deploy → **View logs**. Use the **Deploy** (runtime) logs, not Build. Look for: `Entrypoint: PORT=...`, `Running database migrations`, `Seeding the database`, `Starting the server`, and `Listening at http://...`. If logs stop before `Listening at`, the failure is there (e.g. migrate/seed error or missing env). Ensure the service deploys from the branch that has the PORT fix (e.g. `feature/agent-forge`). + --- ## Generate random strings (for ACCESS_TOKEN_SALT and JWT_SECRET_KEY) diff --git a/docker/entrypoint.sh b/docker/entrypoint.sh index 440886903..019abefb8 100755 --- a/docker/entrypoint.sh +++ b/docker/entrypoint.sh @@ -2,11 +2,12 @@ set -ex +echo "Entrypoint: PORT=${PORT:-not set}" echo "Running database migrations" npx prisma migrate deploy echo "Seeding the database" -npx prisma db seed +npx prisma db seed || echo "Seed failed (non-fatal), continuing..." -echo "Starting the server" +echo "Starting the server on port ${PORT:-3000}" exec node main