chore: add health route
This commit is contained in:
parent
6da1f91c2f
commit
58b86d545e
@ -177,6 +177,9 @@ func getRoutes(router *gin.Engine, cfg *cfg.Config, users *UsersAccounts, mdlsUs
|
||||
file,
|
||||
)
|
||||
})
|
||||
router.GET("/v1/health", func(c *gin.Context) {
|
||||
c.JSON(http.StatusOK, gin.H{"status": "ok"})
|
||||
})
|
||||
if cfg.UseJWT {
|
||||
router.NoRoute(routenv.AuthMiddleware.MiddlewareFunc(), func(c *gin.Context) {
|
||||
claims := jwt.ExtractClaims(c)
|
||||
|
Loading…
x
Reference in New Issue
Block a user