Redis Stack packages Redis with modules that support multiple data structures, text search, secondary indexing, and vector similarity search. It can serve as a fast, multimodel data store and query engine for applications such as semantic search and retrieval workflows. section 8.2
A local Redis Stack setup typically includes:
- A Redis Stack Docker container using the redis/redis-stack:latest image. section 8.2
- Exposed Redis and management ports, configurable for the environment. section 8.2
- A persistent data volume and a health check that verifies Redis responds. section 8.2
- Docker installed and running, plus the redis-py package for Python access. section 8.2
Listing 8.1 docker-compose file for redis-stack
version: '3.7'
services:
vector-db:
image: redis/redis-stack:latest
ports:
- 6379:6379
- 8001:8001
environment:
- REDISEARCH_ARGS=CONCURRENT_WRITE_MODE
volumes:
- vector-db:/var/lib/redis
- ./redis.conf:/usr/local/etc/redis/redis.conf
healthcheck:
test: ["CMD", "redis-cli", "-h", "localhost", "-p", "6379", "ping"]
interval: 2s
timeout: 1m30s
retries: 5
start_period: 5s
volumes:
vector-db:
Use the docker-compose configuration to start Redis Stack with persistence, exposed ports, concurrent write mode, and a readiness check. section 8.2
