Linux - Install redis-cli only Linux - Install redis-cli only linux linux

Linux - Install redis-cli only


Ubuntu (tested on 14.04) has package called redis-tools which contains redis-cli among other tools.To install it type:

sudo apt-get install redis-tools


Instead of redis-cli you can simply use nc!

nc -v --ssl redis.mydomain.com 6380

Then submit the commands.


From http://redis.io/topics/quickstart

wget http://download.redis.io/redis-stable.tar.gztar xvzf redis-stable.tar.gzcd redis-stablemake redis-clisudo cp src/redis-cli /usr/local/bin/

With Docker I normally use https://registry.hub.docker.com/_/redis/. If I need to add redis-cli to an image I use the following snippet.

RUN cd /tmp &&\    curl http://download.redis.io/redis-stable.tar.gz | tar xz &&\    make -C redis-stable &&\    cp redis-stable/src/redis-cli /usr/local/bin &&\    rm -rf /tmp/redis-stable