Clear Redis cache from your docker container
Mar 15, 2022
Sometimes need to clear all Redis
cache for your Doker container.
docker exec -it container-name redis-cli FLUSHALL
For automating this process you can add the alias
to ~/.bash_profile
or ~/.basrc
. Example:
alias redis-flush="docker exec -it container-name redis-cli FLUSHALL"