79098957

Date: 2024-10-17 16:08:03
Score: 1.5
Natty:
Report link

On September, 2024, Heroku updated REDIS to use a secure TLS connection URL. See this Help article for more information on what config var changes you must make to your Redis configuration.

In my case, I was using redis.Redis python function to create the connection like this:

import os
from urllib.parse import urlparse
import redis

url = urlparse(os.environ.get("REDIS_URL"))
r = redis.Redis(host=url.hostname, port=url.port, password=url.password, ssl=(url.scheme == "rediss"), ssl_cert_reqs=None)

I was missing the parameters ssl=(url.scheme == "rediss") and ssl_cert_reqs=None

How to fix?

Make sure you are specifying the SSL related configuration parameters ssl=True and ssl_cert_reques=None

Reasons:
  • RegEx Blacklisted phrase (1.5): How to fix?
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • Low reputation (0.5):
Posted by: Alejandro Sanchez