This project provides a ready-to-use Redis Cluster Docker image designed for developers and testers who need a quick, reliable, and isolated cluster environment. Instead of manually configuring multiple Redis instances, you can launch a fully functional cluster with 6 nodes (3 masters + 3 replicas) inside a single container.

Why Use This Image?

  • Fast Setup: Initialize the cluster once and start working immediately.
  • Lightweight: Runs entirely in a single container, reducing resource overhead.
  • Developer-Friendly: Perfect for local development, integration testing, and CI/CD pipelines.
  • Transparent & Open Source: Source code is available on GitHub for customization and contributions.

Quick Start Guide

Run the container with a single command:

docker run -d -p 30001-30006:30001-30006 --name redis-cluster ercansormaz/redis-cluster

Initialize the cluster:

docker exec -it redis-cluster create-cluster create

Your Redis Cluster will be available on ports 30001–30006.

Useful Commands

Check cluster status:

docker exec -it redis-cluster redis-cli -p 30001 cluster info

List cluster nodes:

docker exec -it redis-cluster redis-cli -p 30001 cluster nodes

Use Cases

  • Local Development: Simulate production-like Redis clustering without complex infrastructure.
  • Testing Environments: Validate application behavior with sharding and replication.
  • CI/CD Pipelines: Automate cluster setup for integration tests.
  • Learning & Experimentation: Explore Redis Cluster features in a safe sandbox.