Docker-based Redis cluster development environment with multiple topologies (Cluster, Master-Slave, Sentinel) and Redis Insight integration
Quick setup tool for different Redis cluster topologies using Docker Compose. Perfect for local development with OrbStack, Docker Desktop, or any Docker environment.
β οΈ Security Notice: This setup is designed for LOCAL DEVELOPMENT ONLY. See SECURITY.md for production security considerations.
# Clone or download this project
cd redis-cluster-dev
# Choose your Redis topology:
cd redis-cluster && ./start.sh # Redis Cluster (sharding)
cd redis-master-slave && ./start.sh # Master-Slave replication
cd redis-sentinel && ./start.sh # Sentinel high availability
redis-cluster/redis-master-slave/redis-sentinel/All configurations use Redis 8.2 (latest stable) with optimized settings:
allkeys-lruEach setup includes Redis Insight - the official Redis GUI for monitoring, managing, and visualizing your Redis data:
Redis Cluster: http://localhost:5540
Master-Slave: http://localhost:5541
Sentinel: http://localhost:5542
cd redis-cluster
./start.sh
# Connect to cluster (internal connection via Docker exec)
docker exec redis-cluster-node-1 redis-cli -c -p 6379
# Test sharding (external connections via mapped ports)
redis-cli -c -p 7001 set key1 "value1"
redis-cli -c -p 7002 get key1 # Automatically redirected
cd redis-master-slave
./start.sh
# Write to master
docker exec redis-master redis-cli set key1 "value1"
# Read from slave
docker exec redis-slave-1 redis-cli get key1
cd redis-sentinel
./start.sh
# Check sentinel status
docker exec redis-sentinel-1 redis-cli -p 26379 sentinel masters
# Test failover (stop master)
docker stop redis-sentinel-master
docker exec redis-sentinel-1 redis-cli -p 26379 sentinel masters
# Stop and remove containers
docker-compose down
# Remove volumes (data will be lost)
docker-compose down -v
# Interactive setup menu (includes Redis Insight options)
./setup.sh
# Redis Insight configuration helper
./configure-insight.sh
./configure-insight.sh# Check running Redis Insight containers
docker ps | grep redis-insight
# Restart Redis Insight for a specific topology
cd redis-cluster && docker-compose restart redis-insight-cluster
# View Redis Insight logs
docker logs redis-insight-cluster
Each setup includes connection details and testing commands in the startup output. Use Redis CLI, Redis Insight web interface, or your favorite Redis client to connect and explore.
Redis Version: 8.2 (latest stable)
Compatibility: OrbStack, Docker Desktop, Podman