Skip to content

Commit

Permalink
feat(health-server): bypass authentication with AuthFuncOverride
Browse files Browse the repository at this point in the history
  • Loading branch information
tolgaOzen committed Feb 17, 2024
1 parent 6fcdf1c commit 2e99867
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions internal/servers/healthServer.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,8 @@ func (s *HealthServer) Watch(_ *health.HealthCheckRequest, _ health.Health_Watch
// Example of how to register both methods but only implement the Check method.
return status.Error(codes.Unimplemented, "unimplemented")
}

// AuthFuncOverride is called instead of authn.
func (s *HealthServer) AuthFuncOverride(ctx context.Context, fullMethodName string) (context.Context, error) {
return ctx, nil
}

0 comments on commit 2e99867

Please sign in to comment.