Issue
Your app is no longer connecting to Redis and you are seeing errors relating to self-signed certificates.
Eg: <OpenSSL::SSL::SSLError: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain)> SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain)
Resolution
Production plans (Premium and higher) of Heroku Data for Redis running Redis 6+ require TLS connections. Heroku Data for Redis uses self-signed certificates, which can require you to configure the verify_mode
SSL setting of your Redis client.
To disable certificate verification, add { verify_mode: OpenSSL::SSL::VERIFY_NONE }
(or your language equivalent) to your Redis connection configuration. We have example implementations for the following languages:
- Java
- Ruby
- Python
- Node.js
- Go
-
PHP - Please note that in PHP
{ verify_mode: OpenSSL::SSL::VERIFY_NONE }
is known as[verify_peer_name]
. An example implementation is using?ssl[verify_peer_name]=0&ssl[verify_peer]=0
with the latest Predis. More info on connecting in PHP.
See Connecting to Heroku Data for Redis for details and further examples on setting up TLS connections.