예제 #1
0
func main() {
	if beego.RunMode == "dev" {
		beego.DirectoryIndex = true
		beego.StaticDir["/swagger"] = "swagger"
	}
	toolbox.AddHealthCheck("database", &healthcheck.CitycontentCheck{})
	toolbox.AddHealthCheck("citycontent", &healthcheck.DatabaseCheck{})
	//collector.Run()
	beego.Run()
}
예제 #2
0
파일: main.go 프로젝트: everfore/fservice
func toolbox_init() {
	// toolbox healthcheck task
	beego.EnableAdmin = true
	beego.AdminHttpAddr = "localhost"
	beego.AdminHttpPort = 8088
	toolbox.AddHealthCheck("database", &DatabaseCheck{})
	go a()
}