-
Notifications
You must be signed in to change notification settings - Fork 2.4k
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
Unable to connect ClusterClient to Azure Cache for Redis #1698
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
After further analysis I assume the standard Client correctly connects via DNS while the ClusterClient tries to connect via IP address... this causes issues because the Azure certificate is only valid for the hostname present in the Subject field of the certificate. |
@johannesvietze it uses the address returned by https://redis.io/commands/cluster-slots . |
Thanks for your help. I Just checked: executing What would be your recommendation to connect redis-go with the Azure Redis Cluster under these circumstances? The only possibility I see is to overwrite the |
No ideas here. I would expect Azure Cache team to have some solution. |
I've opened a ticket with them and will post updates here. In the meantime, I managed to work around it by passing in my own |
Response from azure support:
and
|
you can try redis.NewClusterClient(&redis.ClusterOptions{
Addrs: []string{"..."},
TLSConfig: &tls.Config{
ServerName: "you domain",
},
}) |
Awesome, that's the solution. Thank you! |
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
Uh oh!
There was an error while loading. Please reload this page.
I'm unable to establish a connection to Azure Cache for Redis, when using the ClusterClient:
This issue might be related to #1691 ? Any ideas?
/edit: formatting
/edit2: I'm using go-redis v8.6.0, tried on MacOS & Linux
The text was updated successfully, but these errors were encountered: