[ 项目 ] 修改CI CD流程 - 2
This commit is contained in:
@@ -14,18 +14,19 @@ func main() {
|
||||
|
||||
// 解析命令行参数
|
||||
var version string
|
||||
var agentInfoConf string
|
||||
var agentServerInfoConf string
|
||||
flag.StringVar(&version, "version", "", "config file version")
|
||||
flag.StringVar(&agentInfoConf, "agentInfoConf", "", "agent server info conf file")
|
||||
flag.StringVar(&agentServerInfoConf, "agentServerInfoConf", "", "agent server info conf file")
|
||||
flag.Parse()
|
||||
// 读取对应版本的配置文件
|
||||
filename := fmt.Sprintf("octopus-agent-%s.yaml", version)
|
||||
println("config file name is => " + filename)
|
||||
println("agent server info file is => " + agentServerInfoConf)
|
||||
|
||||
// 初始化Nacos的连接配置
|
||||
g.G.AgentConfig = register.ParseConfiguration(filename)
|
||||
|
||||
// 执行初始化之策工作
|
||||
AgentServerInfoCache = INIT()
|
||||
AgentServerInfoCache = INIT(agentServerInfoConf)
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user