feat: backend core - auth, user, role, permission, device, webhook, monitoring, cache, repository, service, middleware, API handlers
2026-04-02 11:19:50 +08:00
|
|
|
package main
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"log"
|
|
|
|
|
|
2026-05-30 21:29:24 +08:00
|
|
|
_ "github.com/user-management-system/docs"
|
feat: backend core - auth, user, role, permission, device, webhook, monitoring, cache, repository, service, middleware, API handlers
2026-04-02 11:19:50 +08:00
|
|
|
"github.com/user-management-system/internal/config"
|
2026-04-19 08:59:00 +08:00
|
|
|
"github.com/user-management-system/internal/server"
|
feat: backend core - auth, user, role, permission, device, webhook, monitoring, cache, repository, service, middleware, API handlers
2026-04-02 11:19:50 +08:00
|
|
|
)
|
|
|
|
|
|
2026-05-30 21:29:24 +08:00
|
|
|
// @title User Management System API
|
|
|
|
|
// @version 1.0
|
|
|
|
|
// @description API for user management, authentication, authorization, and administration.
|
|
|
|
|
// @BasePath /api/v1
|
|
|
|
|
// @schemes http https
|
feat: backend core - auth, user, role, permission, device, webhook, monitoring, cache, repository, service, middleware, API handlers
2026-04-02 11:19:50 +08:00
|
|
|
func main() {
|
|
|
|
|
// 加载配置
|
|
|
|
|
cfg, err := config.Load()
|
|
|
|
|
if err != nil {
|
|
|
|
|
log.Fatalf("load config failed: %v", err)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 启动服务器
|
2026-04-19 08:59:00 +08:00
|
|
|
if err := server.Serve(cfg); err != nil {
|
|
|
|
|
log.Fatalf("server failed: %v", err)
|
feat: backend core - auth, user, role, permission, device, webhook, monitoring, cache, repository, service, middleware, API handlers
2026-04-02 11:19:50 +08:00
|
|
|
}
|
|
|
|
|
}
|