R
Join ServerRailway
βο½help
Application failed to respond
My nx app get that error:
nix packs configuration:
yarn run v1.22.19
$ nx serve app --prod --port 5564
> nx run app:serve:production --port 5564
info - Loaded env from /app/packages/app/.env.local
[ ready ] on http://localhost:5564
nix packs configuration:
{
"$schema": "https://railway.app/railway.schema.json",
"build": {
"builder": "NIXPACKS",
"buildCommand": "yarn build app --prod"
},
"deploy": {
"numReplicas": 1,
"startCommand": "yarn start app --prod --port ${PORT-3001}",
"restartPolicyType": "ON_FAILURE",
"restartPolicyMaxRetries": 10
}
}
32545448-aaa5-4244-804b-a690a9ace33d
can you try adding
--host 0.0.0.0
to your start command?before the port flag is used
Thanks @Brody, just tried and still not working
what status code do you get?
@Brody My site: https://launchpad-app-production.up.railway.app/
show me the new logs please
@Brody
show me the railway.json file
{
"$schema": "https://railway.app/railway.schema.json",
"build": {
"builder": "NIXPACKS",
"buildCommand": "yarn build app --prod"
},
"deploy": {
"numReplicas": 1,
"startCommand": "yarn start app --prod --port ${PORT-3001} --host=0.0.0.0",
"restartPolicyType": "ON_FAILURE",
"restartPolicyMaxRetries": 10
}
}
try this?
Omg @Brody ππ thank you so much, you saved my night
Still not working @Brody
{
"$schema": "https://railway.app/railway.schema.json",
"build": {
"builder": "NIXPACKS",
"buildCommand": "yarn build app --prod"
},
"deploy": {
"numReplicas": 1,
"startCommand": "yarn start app --host 0.0.0.0 --port ${PORT-3001} --prod",
"restartPolicyType": "ON_FAILURE",
"restartPolicyMaxRetries": 10
}
}
yarn run v1.22.19
$ nx serve app --host 0.0.0.0 --port 5438 --prod
> nx run app:serve:production --host 0.0.0.0 --port 5438
info - Loaded env from /app/packages/app/.env.local
[ ready ] on http://localhost:5438
Problem solved, should be:
nx serve app --hostname 0.0.0.0 --port 5438 --prod
ππhehe I took a guess at --host, nx's docs page was frozen for me
glad you could solve it!