Last active
April 8, 2025 14:37
-
-
Save donhenton/dc5a13fcc3d4b581dc60e9beb58c1689 to your computer and use it in GitHub Desktop.
Redis/Redis-commander Docker Compose with Persistence
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
redis: | |
container_name: redis | |
hostname: redis | |
image: redis | |
command: ["redis-server", "--appendonly", "yes"] | |
volumes: | |
- ~/redis/data:/data | |
ports: | |
- "6379:6379" | |
redis-commander: | |
container_name: redis-commander | |
hostname: redis-commander | |
image: rediscommander/redis-commander:latest | |
build: . | |
restart: always | |
environment: | |
- REDIS_HOSTS=local:redis:6379 | |
ports: | |
- 8081:8081 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Question: Is it possible to persist the connections/servers added to redis-commander as well ?
Update
Found the answer. To provide persistence for
redis-commander
we have to bind mount/redis-commander/config
.Just have to add the following under line
18
above.