Last active
December 24, 2023 09:10
-
-
Save abhisekp/af78f71e26d985fb404cc16ec2a0681b to your computer and use it in GitHub Desktop.
Redis Docker Setup
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
# Redis Network | |
docker network create redis | |
# Redis Docker | |
docker run --name redis \ | |
-d \ | |
--net redis \ | |
-v /data/redis:/data \ | |
redis:alpine redis-server \ | |
--appendonly yes \ | |
--save 60 1 \ | |
--rdbcompression yes \ | |
--appendfsync everysec \ | |
--loglevel warning | |
# Redis CLI | |
alias redis-cli='docker exec -it redis redis-cli -h localhost' | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment