Alexandru
Explore posts from servers"Unlink" services across environments
I believe this might have happened when I cloned the environments, but I have 3 envs: dev, staging, production. Each has a frontend/backend. When I rename the frontend service in dev, the stage frontend service gets renamed. Looking at the RAILWAY_SERVICE_ID env vars for the services, they are the same. They have different settings within each environment. How can I "unlink" the services so I can have different names in different environments.
15 replies
Disable HTTP Logs for specific endpoint
It looks like the HTTP Logs provide a history of a set amount of logs (let's say 100). I set up a load balancer that checks the /health endpoing every 60 seconds, so I see all the GET requests from the load balancer in the HTTP Logs, and they take up the limited history available. I can filter the logs
- @path:/health
but that still only filters out of the available (for example again 100) logs.
Is there a way to not log those HTTP requests at all?7 replies
Setting up load balancer in cloudflare (from the guide) and us-east service doesn't get health check
I'm using this guide to set up load balancer with proximity steering on my project. I set up 2 endpoints for 2 separate copies of my backend service, one on us-east4 and the other on us-west1. Both have a healthcheck endpoint.
The west service gets the healthcheck as expected, the east service doesn't get the healthcheck, but it gets other requests. Also, I enabled session affinity on load balancer for websockets, and they don't work.
If I take down the us-east4 service, and route everything to us-west1, the websockets work just fine.
9 replies
Service stuck in Building phase, tried re-deploying
I have a service that was working fine, but I need to redeploy it because I changed some env vars, but I've re-deployed 3 times now, and every time it's stuck in the Building the image ... phase for over 10-15 mins.
https://railway.app/project/bffee644-ec55-4122-9e19-fee98c401647/service/05cba2ee-b344-4910-b0de-626add3247f7
15 replies
Outside requests receiving HTTP 502 Bad Gateway
Between 14:37-14:40 UTC, external (webhooks) requests hitting our api deployed in Railway were receiving HTTP 502 Bad Gateway errors. Looking through our logs, the service was working normally. Are you able to see what the logs from Railway say as far as what our service was responding?
Project ID: bffee644-ec55-4122-9e19-fee98c401647
Service ID: bbf223dd-a2e6-4b7c-bd55-1dfac13e263a
URL: https://railway.app/project/bffee644-ec55-4122-9e19-fee98c401647/service/bbf223dd-a2e6-4b7c-bd55-1dfac13e263a
16 replies
Deployed service not reachable from outside requests, HTTP 502 Bad Gateway
Between 14:47 - 14:55 UTC, external webhooks trying to reach our service deployed in Railway were receiving HTTP 502 Bad Gateway erros.
The specific service that his was happening for is https://railway.app/project/bffee644-ec55-4122-9e19-fee98c401647/service/bbf223dd-a2e6-4b7c-bd55-1dfac13e263a
3 replies
HTTP 502 Bad Gateway using the $PORT variable assigned by Railway + other service reference $PORT
I have a next.js front end deployed as a railway project, when I set the $PORT variable to 3000, the service starts and works fine. If I remove the $PORT variable and just rely on the $PORT provided by railway, the project builds fine, but when I try to access the public url, I get a 502 Bad Gateway error.
Also, my front end connects to a backend service in the same project, if that backend also uses the provided $PORT from railway, can the frontend access it by setting its API_URL env var to "http://${{backend.RAILWAY_PRIVATE_DOMAIN}}:${{backend.PORT}}"?
58 replies
Redis Client Error Error: getaddrinfo ENOTFOUND redis.railway.internal
Hello, I have a next.js project deploying in a railway service with a redis service attached. I set the REDIS_URL variable on the next project to ${{Redis.REDIS_PRIVATE_URL}}, and I can see from my logs that the app tries to connect to the internal url: "REDIS_URL: redis://default:[email protected]:6379". However, when my redis client (using redis package) tries to connect to that url, I get this error:
#13 29.05 app:build: Redis Client Error Error: getaddrinfo ENOTFOUND redis.railway.internal #13 29.05 app:build: at GetAddrInfoReqWrap.onlookupall [as oncomplete] (node:dns:120:26) { #13 29.05 app:build: errno: -3008, #13 29.05 app:build: code: 'ENOTFOUND', #13 29.05 app:build: syscall: 'getaddrinfo', #13 29.05 app:build: hostname: 'redis.railway.internal' #13 29.05 app:build: }If I switch to use the ${{Redis.REDIS_URL}} that uses the proxy, the connection works. URL to the build logs: https://railway.app/project/bffee644-ec55-4122-9e19-fee98c401647/service/05cba2ee-b344-4910-b0de-626add3247f7?id=ea6d0f24-f702-49ee-9b81-f69b204fa30e#build
9 replies