nacos config
This commit is contained in:
@@ -17,9 +17,8 @@ var configFile = flag.String("f", "etc/{{.serviceName}}.yaml", "the config file"
|
||||
func main() {
|
||||
flag.Parse()
|
||||
|
||||
cfgContent := fsconfig.StartNacosConfig(configFile,nil)
|
||||
var c config.Config
|
||||
conf.LoadConfigFromYamlBytes([]byte(cfgContent),&c)
|
||||
fsconfig.StartNacosConfig(*configFile, &c, nil)
|
||||
|
||||
c.Timeout = int64(time.Second * 15)
|
||||
server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) {
|
||||
|
||||
Reference in New Issue
Block a user