diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 47d94c212..eda2ea3f7 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -185,6 +185,8 @@ jobs: SVR_HTTP_PORT=$((9380 + RUNNER_NUM * 10)) ADMIN_SVR_HTTP_PORT=$((9381 + RUNNER_NUM * 10)) SVR_MCP_PORT=$((9382 + RUNNER_NUM * 10)) + GO_HTTP_PORT=$((9384 + RUNNER_NUM * 10)) + GO_ADMIN_PORT=$((9385 + RUNNER_NUM * 10)) SANDBOX_EXECUTOR_MANAGER_PORT=$((9385 + RUNNER_NUM * 10)) SVR_WEB_HTTP_PORT=$((80 + RUNNER_NUM * 10)) SVR_WEB_HTTPS_PORT=$((443 + RUNNER_NUM * 10)) @@ -205,6 +207,8 @@ jobs: echo -e "SVR_HTTP_PORT=${SVR_HTTP_PORT}" >> docker/.env echo -e "ADMIN_SVR_HTTP_PORT=${ADMIN_SVR_HTTP_PORT}" >> docker/.env echo -e "SVR_MCP_PORT=${SVR_MCP_PORT}" >> docker/.env + echo -e "GO_HTTP_PORT=${GO_HTTP_PORT}" >> docker/.env + echo -e "GO_ADMIN_PORT=${GO_ADMIN_PORT}" >> docker/.env echo -e "SANDBOX_EXECUTOR_MANAGER_PORT=${SANDBOX_EXECUTOR_MANAGER_PORT}" >> docker/.env echo -e "SVR_WEB_HTTP_PORT=${SVR_WEB_HTTP_PORT}" >> docker/.env echo -e "SVR_WEB_HTTPS_PORT=${SVR_WEB_HTTPS_PORT}" >> docker/.env diff --git a/cmd/admin_server.go b/cmd/admin_server.go index 291f7868e..fae63a0e8 100644 --- a/cmd/admin_server.go +++ b/cmd/admin_server.go @@ -159,7 +159,7 @@ func main() { // Start server in a goroutine go func() { - logger.Info(fmt.Sprintf("Version: %s", utility.GetRAGFlowVersion())) + logger.Info(fmt.Sprintf("Admin Go Version: %s", utility.GetRAGFlowVersion())) logger.Info(fmt.Sprintf("Starting RAGFlow admin server on port: %d", cfg.Admin.Port)) if err := srv.ListenAndServe(); err != nil && err != http.ErrServerClosed { logger.Fatal("Failed to start server", zap.Error(err)) diff --git a/cmd/server_main.go b/cmd/server_main.go index a6eb3408b..cc2510ec8 100644 --- a/cmd/server_main.go +++ b/cmd/server_main.go @@ -216,7 +216,7 @@ func startServer(config *server.Config) { " / _, _// ___ |/ /_/ // __/ / // /_/ /| |/ |/ /\n" + " /_/ |_|/_/ |_|\\____//_/ /_/ \\____/ |__/|__/\n", ) - logger.Info(fmt.Sprintf("Version: %s", utility.GetRAGFlowVersion())) + logger.Info(fmt.Sprintf("RAGFlow Go Version: %s", utility.GetRAGFlowVersion())) logger.Info(fmt.Sprintf("Server starting on port: %d", config.Server.Port)) if err := srv.ListenAndServe(); err != nil && err != http.ErrServerClosed { logger.Fatal("Failed to start server", zap.Error(err)) diff --git a/docker/.env b/docker/.env index 79f4f91b3..c7e68a756 100644 --- a/docker/.env +++ b/docker/.env @@ -152,6 +152,8 @@ SVR_WEB_HTTPS_PORT=443 SVR_HTTP_PORT=9380 ADMIN_SVR_HTTP_PORT=9381 SVR_MCP_PORT=9382 +GO_HTTP_PORT=9384 +GO_ADMIN_PORT=9385 # The RAGFlow Docker image to download. v0.22+ doesn't include embedding models. RAGFLOW_IMAGE=infiniflow/ragflow:v0.24.0 diff --git a/internal/server/config.go b/internal/server/config.go index acdcf4c01..111dec213 100644 --- a/internal/server/config.go +++ b/internal/server/config.go @@ -337,9 +337,9 @@ func Init(configPath string) error { globalConfig.Admin.Host = "127.0.0.1" } if globalConfig.Admin.Port == 0 { - globalConfig.Admin.Port = 9383 + globalConfig.Admin.Port = 9385 } else { - globalConfig.Admin.Port += 2 + globalConfig.Admin.Port += 4 } // Load REGISTER_ENABLED from environment variable (default: 1) @@ -374,7 +374,7 @@ func Init(configPath string) error { if v.IsSet("ragflow") { ragflowConfig := v.Sub("ragflow") if ragflowConfig != nil { - globalConfig.Server.Port = ragflowConfig.GetInt("http_port") + 2 // 9382, by default + globalConfig.Server.Port = ragflowConfig.GetInt("http_port") + 4 // 9384, by default //globalConfig.Server.Port = ragflowConfig.GetInt("http_port") // Correct // If mode is not set, default to debug if globalConfig.Server.Mode == "" {