From 3832b05308307ef068c438b1df3d2f6f8ad2acc6 Mon Sep 17 00:00:00 2001 From: Andy Pack Date: Mon, 20 May 2024 17:03:24 +0100 Subject: [PATCH] adding health endpoint for k8s --- Selector.Web/Controller/HealthController.cs | 24 +++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 Selector.Web/Controller/HealthController.cs diff --git a/Selector.Web/Controller/HealthController.cs b/Selector.Web/Controller/HealthController.cs new file mode 100644 index 0000000..a7120a2 --- /dev/null +++ b/Selector.Web/Controller/HealthController.cs @@ -0,0 +1,24 @@ +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; + +namespace Selector.Web.Controller +{ + + [ApiController] + [Route("health")] + public class HealthController : Microsoft.AspNetCore.Mvc.Controller + { + public HealthController() + { + + } + + [HttpGet] + [AllowAnonymous] + public Task Health() + { + return Task.FromResult(Ok()); + } + } +} \ No newline at end of file