This commit is contained in:
2025-07-19 02:03:24 +08:00
commit ac6eeff8c9
44 changed files with 10305 additions and 0 deletions

21
cmd/main.go Normal file
View File

@ -0,0 +1,21 @@
package main
import (
"unR2/internal/config"
"unR2/internal/initialize"
"unR2/internal/pkg/logger"
"unR2/internal/router"
)
func main() {
config.InitConfig()
logCfg := config.Conf.Log
logger.InitLogger(logCfg.Level, logCfg.Format, logCfg.Output)
initialize.InitDB()
r := router.SetupRouter()
logger.Log.Info("🚀 Server running on :" + config.Conf.Server.Port)
if err := r.Run(":" + config.Conf.Server.Port); err != nil {
logger.Log.Error(err.Error())
}
}