
Deploy Redis | (Just Updated) Official Redis 8, Password Set, Data Survives Redeploys
Official Redis 8, password set, AOF on a volume, TCP proxy
redis
Just deployed
/data
Deploy and Host Redis on Railway
Redis is the in-memory data store behind caches, queues, rate limiters and session stores. This template runs the official Redis 8 image as a single service from a digest-pinned image, with the port on a Railway TCP proxy and a Railway volume holding the persistence files.
About Hosting Redis
- A password is required from the first connection.
REDIS_PASSWORDis generated per deploy; unauthenticated clients getNOAUTH Authentication required. - Your data survives redeploys. The data directory
/datais a Railway volume with append-only persistence (appendfsync everysec) plus RDB snapshots. The start command fixes the volume's ownership at boot and prints the mount owner in the deploy log so you can confirm it. - Memory and threads follow your plan.
maxmemoryis set to 70% of the container's memory limit and I/O threads to the container's CPU count, read from the cgroup rather than the host. The eviction policy isnoeviction, so Redis refuses writes instead of silently dropping keys. - Two ways in. Services in the same project use the private URL; clients elsewhere use the TCP proxy URL.
Common Use Cases
- A cache or session store in front of a web application
- A job queue backend for BullMQ, Sidekiq, Celery or RQ
- Rate limiting and distributed locks
- A backing store for self-hosted apps that require Redis (n8n queue mode, Chatwoot, Plane)
Dependencies for Redis Hosting
- One Railway volume for the data directory (created by the template)
Deployment Dependencies
- Redis documentation: https://redis.io/docs/
- Official image: https://hub.docker.com/_/redis
Implementation Details
| Variable | Purpose |
|---|---|
REDIS_PASSWORD | Password for the default user, generated per deploy. |
REDIS_PRIVATE_URL | Connection string on the private network, for services in the same project. |
REDIS_PUBLIC_URL | Connection string on the TCP proxy, for clients outside Railway. |
Connect from your machine:
redis-cli -u "$REDIS_PUBLIC_URL"
Why Deploy Redis on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying Redis on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Template Content
redis
redis:8.8.3