Fail gracefully on grpc listening error (#4118)

This commit is contained in:
6543 2024-09-16 18:40:09 +02:00 committed by GitHub
parent 4dd4d9755d
commit 4289853322
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -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")