add initial application structure with configuration, logging, and health check endpoints

This commit is contained in:
kever
2026-01-14 23:58:00 +08:00
commit fed727e593
31 changed files with 770 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
package controller
import (
"net/http"
"github.com/labstack/echo/v4"
"epic-ent/internal/service"
)
type HealthController struct {
svc *service.HealthService
}
func NewHealthController(svc *service.HealthService) *HealthController {
return &HealthController{svc: svc}
}
func (h *HealthController) Health(c echo.Context) error {
status := h.svc.Check()
return c.JSON(http.StatusOK, status)
}