Documentation

services

Redis

Managed Redis cache for sessions, queues, and real-time data.

Add a managed Redis instance to your deployment for caching, session storage, pub/sub messaging, or as a job queue backend.

When to Use#

  • Application caching (API responses, database query results)
  • Session storage
  • Job queue backend (BullMQ, Sidekiq, Celery)
  • Real-time pub/sub messaging
  • Rate limiting

Configuration#

runix.yaml
yaml
services:
  - name: cache
    type: redis

  - name: api
    type: web-service
    repo: https://github.com/alice/api
    env:
      REDIS_URL: "${cache.connection_string}"

Connection String#

The connection string follows the standard Redis URL format:

text
redis://hostname:6379

Redis data is stored in memory by default. If the container restarts, cached data is lost. Enable persistence in the dashboard if you need data to survive restarts.