From d76740e5e7c6b166574c5576dee08f88070eff46 Mon Sep 17 00:00:00 2001 From: Brendan Chen Date: Mon, 31 Mar 2025 23:37:28 -0700 Subject: [PATCH] add tls config --- src/repositories/RedisNotificationRepository.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/repositories/RedisNotificationRepository.ts b/src/repositories/RedisNotificationRepository.ts index 1690c50..ad189bf 100644 --- a/src/repositories/RedisNotificationRepository.ts +++ b/src/repositories/RedisNotificationRepository.ts @@ -15,6 +15,10 @@ export class RedisNotificationRepository implements NotificationRepository { constructor( private redisClient = createClient({ url: process.env.REDIS_URL, + socket: { + tls: (process.env.REDIS_URL?.match(/rediss:/) != null), + rejectUnauthorized: false, + } }), ) { this.getAllNotificationsForShuttleAndStopId = this.getAllNotificationsForShuttleAndStopId.bind(this);