From f757d8232b56b5d94ed853a6e6c00763905f8610 Mon Sep 17 00:00:00 2001 From: Kyle Lacy Date: Sat, 15 Apr 2023 12:32:54 -0700 Subject: [PATCH] Add setting to disable extra TLS config for Celery broker connection --- apiserver/plane/settings/production.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/apiserver/plane/settings/production.py b/apiserver/plane/settings/production.py index 8f8453aff..a3f2ea79d 100644 --- a/apiserver/plane/settings/production.py +++ b/apiserver/plane/settings/production.py @@ -239,8 +239,12 @@ SLACK_BOT_TOKEN = os.environ.get("SLACK_BOT_TOKEN", False) LOGGER_BASE_URL = os.environ.get("LOGGER_BASE_URL", False) +broker_ssl = os.environ.get("REDIS_BROKER_SSL", "1") == "1" redis_url = os.environ.get("REDIS_URL") -broker_url = f"{redis_url}?ssl_cert_reqs={ssl.CERT_NONE.name}&ssl_ca_certs={certifi.where()}" +if broker_ssl: + broker_url = f"{redis_url}?ssl_cert_reqs={ssl.CERT_NONE.name}&ssl_ca_certs={certifi.where()}" +else: + broker_url = redis_url CELERY_RESULT_BACKEND = broker_url -CELERY_BROKER_URL = broker_url \ No newline at end of file +CELERY_BROKER_URL = broker_url