login fix
This commit is contained in:
@@ -6,6 +6,7 @@ import (
|
||||
"strings"
|
||||
|
||||
"nearle/services"
|
||||
"nearle/utils"
|
||||
|
||||
"github.com/gofiber/fiber/v2"
|
||||
)
|
||||
@@ -93,6 +94,15 @@ func (ctl *HealthController) Health(c *fiber.Ctx) error {
|
||||
"code": http.StatusOK, "status": true, "message": "Success",
|
||||
"details": fiber.Map{
|
||||
"version": buildVersion(),
|
||||
// Can this server issue console sessions at all?
|
||||
//
|
||||
// `attachWebSession` logs a minting failure and lets the login
|
||||
// succeed without a token, so a server with no signing secret hands
|
||||
// out sessions that cannot authenticate: the console renders, and
|
||||
// every request after it comes back 401 with no `authorization`
|
||||
// header on it. False here is that, stated once, instead of found
|
||||
// by reading request headers on a Friday morning.
|
||||
"sessions": utils.WebTokenConfigured(),
|
||||
// True when a model is configured and the assistant can answer. False
|
||||
// is the answer to "I set the key and redeployed, did it take?" —
|
||||
// which took a day to establish without it.
|
||||
|
||||
Reference in New Issue
Block a user