Last active
May 6, 2024 15:52
-
-
Save crazyoptimist/e5717e66161630d0b87f0e4588e24163 to your computer and use it in GitHub Desktop.
Redis with Docker Compose
This file contains 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
name: redis | |
services: | |
redis: | |
image: redis:7 | |
container_name: redis | |
command: "redis-server --loglevel warning" | |
volumes: | |
- redis_data:/data/ | |
ports: | |
- "6379:6379" | |
<<: &default_logging | |
logging: | |
driver: "json-file" | |
options: | |
max-size: "200k" | |
max-file: "10" | |
restart: always | |
redis-commander: | |
container_name: redis-commander | |
image: rediscommander/redis-commander:latest | |
environment: | |
- REDIS_HOST=redis | |
- REDIS_PORT=6379 | |
- REDIS_DB=1 # 1-15 possible names | |
ports: | |
- "8081:8081" | |
<<: *default_logging | |
restart: "no" | |
volumes: | |
redis_data: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment