From d54b410429f02dd411367fe442d6c689c47b8796 Mon Sep 17 00:00:00 2001 From: Marc 'risson' Schmitt Date: Tue, 2 Jan 2024 21:01:53 +0100 Subject: [PATCH] outposts/proxy: better Redis error message (#8044) * outposts/proxy: better Redis error message Signed-off-by: Marc 'risson' Schmitt * Update internal/outpost/proxyv2/application/session.go Co-authored-by: Jens L. Signed-off-by: Marc 'risson' Schmitt --------- Signed-off-by: Marc 'risson' Schmitt Co-authored-by: Jens L. --- internal/outpost/proxyv2/application/session.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/internal/outpost/proxyv2/application/session.go b/internal/outpost/proxyv2/application/session.go index 468baf4d9..b30934fb4 100644 --- a/internal/outpost/proxyv2/application/session.go +++ b/internal/outpost/proxyv2/application/session.go @@ -13,6 +13,7 @@ import ( "github.com/gorilla/securecookie" "github.com/gorilla/sessions" "github.com/redis/go-redis/v9" + "goauthentik.io/api/v3" "goauthentik.io/internal/config" "goauthentik.io/internal/outpost/proxyv2/codecs" @@ -40,7 +41,7 @@ func (a *Application) getStore(p api.ProxyOutpostConfig, externalHost *url.URL) // New default RedisStore rs, err := redisstore.NewRedisStore(context.Background(), client) if err != nil { - panic(err) + a.log.WithError(err).Panic("failed to connect to redis") } rs.KeyPrefix(RedisKeyPrefix)