fix: use environment variables for HOST/PORT instead of CLI args
Browse filesSvelteKit's Node adapter reads HOST and PORT from environment variables,
not command line arguments. This was causing the server to not bind
to the correct port, failing the HuggingFace Spaces healthcheck.
- entrypoint.sh +3 -1
entrypoint.sh
CHANGED
|
@@ -15,5 +15,7 @@ if [ "$INCLUDE_DB" = "true" ] ; then
|
|
| 15 |
fi;
|
| 16 |
|
| 17 |
export PUBLIC_VERSION=$(node -p "require('./package.json').version")
|
|
|
|
|
|
|
| 18 |
|
| 19 |
-
dotenv -e /app/.env -c -- node --dns-result-order=ipv4first /app/build/index.js
|
|
|
|
| 15 |
fi;
|
| 16 |
|
| 17 |
export PUBLIC_VERSION=$(node -p "require('./package.json').version")
|
| 18 |
+
export HOST=0.0.0.0
|
| 19 |
+
export PORT=3000
|
| 20 |
|
| 21 |
+
dotenv -e /app/.env -c -- node --dns-result-order=ipv4first /app/build/index.js
|