Esempio n. 1
0
func main() {
	var srv core.Server

	srv.Addr = ":8080"
	http2.ConfigureServer(&srv.Server, nil)

	http.HandleFunc("/", handlers.NewDirList().Reply)

	srv.Init()
	srv.Run()
	srv.Quit()
}
Esempio n. 2
0
func main() {
	var srv core.Server
	var err error

	// _ = "breakpoint"

	setupLogging()

	if err = srv.Init(); err != nil {
		log.Fatal(err)
	}

	if err = srv.Run(); err != nil {
		log.Fatal(err)
	}

	log.Info("Exiting")
	srv.Quit()
}