Redis internal hostname (redis.railway.internal) not reachable from services – forced to use public proxy
claping
PROOP

18 days ago

Hello Railway team,

We are using Redis within our project alongside a worker-based architecture (n8n in queue mode). We would like to report an issue related to Redis internal connectivity.

---

Current Status (Working):

Our system is currently stable using the public connection:

nozomi.proxy.rlwy.net:

With this configuration, all workers can connect to Redis successfully and the system operates without errors.

---

Issue Identified:

We attempted to migrate to the recommended internal connection:

redis.railway.internal:6379

However, when doing so, all workers fail immediately on startup with the following error:

Unable to connect to Redis after trying to connect for 10s

Exiting process due to Redis connection error

This happens even with correct configuration (host, port, username, and password).

---

Technical Conclusion:

In our current environment:

- redis.railway.internal → Not reachable from services

- nozomi.proxy.rlwy.net → Works correctly

This forces us to use the public endpoint for communication between internal services.

---

Additional Observation (Redis logs):

We detected the following message in Redis logs:

Possible SECURITY ATTACK detected. It looks like somebody is sending POST or Host: commands to Redis.

This suggests that the public endpoint is receiving traffic that does not follow the Redis protocol.

---

Questions / Requests:

1. Is it expected behavior that redis.railway.internal is not accessible between services within the same project?

2. Is any additional configuration required to enable internal networking?

3. Are there known limitations with this hostname in certain environments or configurations?

4. What is the recommended best practice for connecting to Redis internally in Railway?

5. Is there a way to restrict or protect the public Redis endpoint to prevent unintended traffic?

---

Objective:

We would like to use a stable internal connection between services for Redis, without relying on the public endpoint.

---

Thank you for your support 🙌

$20 Bounty

1 Replies

Railway
BOT

18 days ago

This thread has been marked as public for community involvement, as it does not contain any sensitive or personal information. Any further activity in this thread will be visible to everyone.

Status changed to Open Railway 18 days ago


You need to use ${{Redis.REDIS_URL}} (this will include the necessary credentials in the URL) in your variable, instead of just using redis.railway.internal:6379 . Or use the following URL format: redis://<user>:<password>@redis.railway.internal:6379

You can read more about reference variables here: https://docs.railway.com/variables#reference-variables


Welcome!

Sign in to your Railway account to join the conversation.

Loading...