diff --git a/src/health/health.controller.ts b/src/health/health.controller.ts index 10137a4..5f5ea66 100644 --- a/src/health/health.controller.ts +++ b/src/health/health.controller.ts @@ -13,13 +13,17 @@ export class HealthController { } @Get('health/live') - live() { - return this.probeService.live(); + async live(@Res({ passthrough: true }) response: Response) { + const report = await this.probeService.live(); + this.applyProbeStatus(response, report.status); + return report; } @Get('health') - healthAlias() { - return this.probeService.live(); + async healthAlias(@Res({ passthrough: true }) response: Response) { + const report = await this.probeService.live(); + this.applyProbeStatus(response, report.status); + return report; } @Get('health/startup')