From 4289853322aa7c6fd84848ea84b8a7f5b53e8e7a Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Mon, 16 Sep 2024 18:40:09 +0200 Subject: [PATCH] Fail gracefully on grpc listening error (#4118) --- cmd/server/grpc_server.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/server/grpc_server.go b/cmd/server/grpc_server.go index 16da47f05..f983bb158 100644 --- a/cmd/server/grpc_server.go +++ b/cmd/server/grpc_server.go @@ -33,7 +33,7 @@ import ( func runGrpcServer(ctx context.Context, c *cli.Command, _store store.Store) error { lis, err := net.Listen("tcp", c.String("grpc-addr")) if err != nil { - log.Fatal().Err(err).Msg("failed to listen on grpc-addr") //nolint:forbidigo + return fmt.Errorf("failed to listen on grpc-addr: %w", err) } jwtSecret := c.String("grpc-secret")