diff --git a/service/Service/Program.cs b/service/Service/Program.cs index 1944e64a0..3c1efe659 100644 --- a/service/Service/Program.cs +++ b/service/Service/Program.cs @@ -166,6 +166,12 @@ public static void Main(string[] args) Console.WriteLine("* Log level : " + app.Logger.GetLogLevelName()); Console.WriteLine("***************************************************************************************************************************"); + // health probe + app.MapGet("/health", () => Results.Ok("Service is running.")) + .Produces(StatusCodes.Status200OK) + .Produces(StatusCodes.Status401Unauthorized) + .Produces(StatusCodes.Status403Forbidden); + app.Logger.LogInformation( "Starting Kernel Memory service, .NET Env: {0}, Log Level: {1}, Web service: {2}, Auth: {3}, Pipeline handlers: {4}", env,