a year ago
Not sure what is going on but the healthcheck was working fine and is now failing, despite me being able to manually call it and receive a 200 status.
endpoint is set to: /healthcheck and it has been working fine for a month. I pushed some changes to my server tonight and it stopped working.
Disabling the healthcheck allows the server to deploy correctly, and when I call the endpoint manually, I receive the expected 200 response:
[06:43:58.333] INFO: incoming request
reqId: "req-2"
req: {
"method": "GET",
"url": "/healthcheck",
"hostname": "ab-phoenix-development.up.railway.app",
"remoteAddress": "192.168.0.3",
"remotePort": 43640
}
[06:43:58.335] INFO: request completed
reqId: "req-2"
res: {
"statusCode": 200
}
responseTime: 1.3350486755371094
ⓘ Deployment information is only viewable by Project members and Railway admins.
12 Replies
a year ago
Are you sure you don't have any middleware interfering with the health check? such as host validation or similar?
What is the reason the health check fails?
a year ago
It just times out.
I have a zod schema that validates the ENV VARS but I don't think that would cause issue - it was also in my code when the healthcheck was working correctly previously.
a year ago
Sorry, that's what I was referencing when I said it just times out:
Attempt #1 failed with service unavailable. Continuing to retry for 4m59s
Attempt #2 failed with service unavailable. Continuing to retry for 4m48s
Attempt #3 failed with service unavailable. Continuing to retry for 4m36s
Attempt #4 failed with service unavailable. Continuing to retry for 4m22s
Attempt #5 failed with service unavailable. Continuing to retry for 4m4s
Attempt #6 failed with service unavailable. Continuing to retry for 3m38s
Attempt #7 failed with service unavailable. Continuing to retry for 2m58s
Attempt #8 failed with service unavailable. Continuing to retry for 2m18s
Attempt #9 failed with service unavailable. Continuing to retry for 1m38s
Attempt #10 failed with service unavailable. Continuing to retry for 58s
Attempt #11 failed with service unavailable. Continuing to retry for 18s
1/1 replicas never became healthy!
Healthcheck failed!
a year ago
but at the same time if I look in the deploy logs it was showing
ab-phoenix@1.0.0 start:fastify /app
pnpm --filter fastify run start
fastify@1.0.0 start /app/packages/core/fastify
sleep 3 && node dist/main.js
PONG
[06:34:30.966] INFO: Server listening at http://0.0.0.0:6965
[06:34:30.967] INFO: Running in production mode
a year ago
Cool, TY.
a year ago
Fix is out, you may add your health check back.
It was conflicting firewall rules.
a month ago
How do you fix the firewall rule?
a month ago
I have spent days trying everything but health check still failling
2 days ago
I am also having this issue , How did you fix it?
2 days ago
Please open your own threads, the issue would be a configuration issue on your end.
Status changed to Closed brody • 2 days ago