Exemplo n.º 1
0
func setupTests() error {
	if isSetUP == true {
		return nil
	}
	isSetUP = true
	s = server.New(SERVER_IP, ADMIN_PORT, BEAT_PORT)
	s.Run()
	c = client.New(SERVER_IP, BEAT_PORT)
	c.Run()
	return nil
}
Exemplo n.º 2
0
func main() {
	serverIP := viper.GetString("server.ip")
	adminPort := viper.GetString("server.adminPort")
	beatPort := viper.GetString("server.beatPort")
	endRunning := make(chan bool, 1)

	s = server.New(serverIP, adminPort, beatPort)
	s.Run()

	<-endRunning
}