From f3df1e42b9ba5f108a8b1e3c48081911c4cbbec2 Mon Sep 17 00:00:00 2001 From: mr Date: Thu, 7 Nov 2024 13:25:26 +0100 Subject: [PATCH] debug --- entrypoint.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/entrypoint.go b/entrypoint.go index 3729715..0da8bda 100644 --- a/entrypoint.go +++ b/entrypoint.go @@ -16,8 +16,8 @@ import ( "cloud.o-forge.io/core/oc-lib/models/collaborative_area/rules/rule" "cloud.o-forge.io/core/oc-lib/models/peer" "cloud.o-forge.io/core/oc-lib/models/resource_model" - "cloud.o-forge.io/core/oc-lib/models/resources/data" "cloud.o-forge.io/core/oc-lib/models/resources/compute" + "cloud.o-forge.io/core/oc-lib/models/resources/data" "cloud.o-forge.io/core/oc-lib/models/resources/processing" "cloud.o-forge.io/core/oc-lib/models/resources/storage" w "cloud.o-forge.io/core/oc-lib/models/resources/workflow" @@ -96,7 +96,7 @@ type LibData struct { Err string `bson:"error" json:"error"` } -func Init(appName string) { +func InitDaemon(appName string) { config.SetAppName(appName) // set the app name to the logger to define the main log chan // create a temporary console logger for init logs.SetLogger(logs.CreateLogger("main")) @@ -116,6 +116,10 @@ func Init(appName string) { beego.BConfig.Listen.HTTPPort = o.GetIntDefault("port", 8080) beego.BConfig.WebConfig.DirectoryIndex = true beego.BConfig.WebConfig.StaticDir["/swagger"] = "swagger" +} + +func Init(appName string) { + InitDaemon(appName) api := &tools.API{} api.Discovered(beego.BeeApp.Handlers.GetAllControllerInfo()) }