Example #1
0
func main() {
	grutil.Autoload()
	router := mux.NewRouter().StrictSlash(true)
	AddRoutes(router)

	port_data := fmt.Sprintf(":%d", grutil.PORT)
	if grutil.HTTPS {
		log.Fatal(http.ListenAndServeTLS(port_data, grutil.CERT, grutil.KEY, nil))
	} else {
		log.Fatal(http.ListenAndServe(port_data, nil))
	}
}
Example #2
0
func main() {
	grutil.Autoload()
	events_listener(grutil.EVENTS_SOCK)
}