amaizfinance/redis-operator

Redis not contactable via dns.

pms1969 opened this issue · 4 comments

Firstly. Great work on producing this operator. It looks very promising, and is exactly what I've been looking for.

I've deployed the operator and an example database having modified the the name.
I was unable to connect to it from an app, so began some investigation, the output of which follows:

$ kubectl -n test exec -ti redis-test-0 -c redis -- sh
/data $ redis-cli -c
127.0.0.1:6379> get foo
"bar"
127.0.0.1:6379> exit
/data $ redis-cli -c -h redis-test
redis-test:6379> get foo
Error: Protocol error, got "H" as reply type byte
/data $ redis-cli -c -h redis-test.test
redis-test.test:6379> get foo
Error: Protocol error, got "H" as reply type byte
/data $ redis-cli -c -h redis-test.test.svc
redis-test.test.svc:6379> get foo
Error: Protocol error, got "H" as reply type byte
/data $ redis-cli -c -h redis-test.test.svc.cluster.local
redis-test.test.svc.cluster.local:6379> get foo
Error: Protocol error, got "H" as reply type byte
/data $ nslookup redis-test
nslookup: can't resolve '(null)': Name does not resolve

Name:      redis-test
Address 1: 10.3.161.25 redis-test.test.svc.cluster.local
/data $

As you can see, using localhost, I can connect and query (added foo earlier) . But if I try and use the service name in any way, it fails.

I noticed that the pods don't have any ports exposed, so I tried editing the statefulset yaml and adding 6379, but got exactly the same result. Also tried with and without the password..

Any ideas?

Hi, I have the same problem as you. Excuse me: has this problem been solved? Or is there an alternative

@wanghe-fit2cloud @pms1969 thanks a lot for reporting the issue!

This has been fixed.

After replacing the operator image with 0.0.2, the problem was fixed!

Thanks for the quick turn around. Might owe you a beer @ the Astronomer some time.