Repository navigation
v0.0.2
nacos-gf
install
go get -u -v github.com/LanceAdd/nacos-gf latestconfig.yaml
nacos:
cloud:
config: true
registry: true
config:
ip: "127.0.0.1"
port: 8848
nameSpaceId: "public"
group: "default"
dataId: "config.yaml"
username: "nacos"
password: "nacos"
registry:
ip: "127.0.0.1"
port: 8848
nameSpaceId: "public"
group: "default"
username: "nacos"
password: "nacos"Usage
package boot
import (
"github.com/LanceAdd/nacos-gf"
)
func init() {
// The parameters of LoadRemoteConfig are custom functions that are used to perform some custom operations after the remote configuration file is updated
nacos.LoadRemoteConfig(ReInitAuth, ReInitSecurity, ReInitSnapShot)
nacos.LoadRegisterConfig()
}