AWS Elasticache SSL connect

By | January 12, 2018

In order to connect to a SSL enabled Redis from cli you would need to first install stunnel:

yum install stunnel

then in the configuration file add:

cat /etc/stunnel/redis-cli.conf
fips = no
setuid = root
setgid = root
pid = /var/run/stunnel.pid
debug = 7
options = NO_SSLv2
options = NO_SSLv3
[redis-cli]
client = yes
accept = 127.0.0.1:6379
connect = MASTER_REDIS_IP:6379
[redis-cli-slave]
client = yes
accept = 127.0.0.1:6380
connect = SLAVE_REDIS_IP:6379

Start the tunnel with:

stunnel /etc/stunnel/redis-cli.conf

then connect:

redis-cli -h localhost -p 6379

.

To connect from ruby you would need to -> https://github.com/redis/redis-rb

Сomments аrchive