sync: 同步 v1.0.4 并脱敏配置与镜像
This commit is contained in:
@@ -3,6 +3,7 @@ package cmd
|
||||
import (
|
||||
"context"
|
||||
"git.5iot.com/iotlcm-public/iotlcm-admin-svr/internal/cmd/inithttp"
|
||||
"git.5iot.com/iotlcm-public/iotlcm-admin-svr/internal/library/exportcenter"
|
||||
"git.5iot.com/iotlcm-public/iotlcm-admin-svr/internal/library/rabbitmq"
|
||||
"git.5iot.com/iotlcm-public/iotlcm-admin-svr/internal/library/websocket"
|
||||
"git.5iot.com/iotlcm-public/iotlcm-admin-svr/internal/router"
|
||||
@@ -17,11 +18,19 @@ import (
|
||||
|
||||
func init() {
|
||||
inithttp.RegisterHttpInitFunc("initJobTask", initJobTask)
|
||||
inithttp.RegisterHttpInitFunc("exportCenter", initExportCenter)
|
||||
inithttp.RegisterHttpCleanupFunc("rabbitmq", func(ctx context.Context) error {
|
||||
return rabbitmq.Close()
|
||||
})
|
||||
}
|
||||
|
||||
// initExportCenter 导出中心:补偿上次进程遗留的任务,并启动过期文件清理。
|
||||
func initExportCenter(ctx context.Context) error {
|
||||
exportcenter.RecoverOnStart(ctx)
|
||||
exportcenter.StartCleanup(ctx)
|
||||
return nil
|
||||
}
|
||||
|
||||
var Http = &gcmd.Command{
|
||||
Name: "http",
|
||||
Usage: "http",
|
||||
|
||||
Reference in New Issue
Block a user