navigator/main.go

25 lines
506 B
Go
Raw Normal View History

2019-10-25 17:16:24 +08:00
package main
import (
"flag"
_ "git.eve.moe/jackyyf/navigator/api/beacon/v1"
_ "git.eve.moe/jackyyf/navigator/api/navigator"
"git.eve.moe/jackyyf/navigator/ipgeo"
"git.eve.moe/jackyyf/navigator/mapping"
2019-10-28 23:29:21 +08:00
"log"
2019-10-25 17:16:24 +08:00
"net/http"
_ "net/http/pprof"
)
2019-10-28 23:29:21 +08:00
var (
listen_spec = flag.String("bind", "127.0.0.1:8086", "http server bind spec")
)
2019-10-25 17:16:24 +08:00
func main() {
flag.Parse()
ipgeo.Initialize()
mapping.Initialize()
2019-10-28 23:29:21 +08:00
log.Println("HTTP server is running on", *listen_spec)
http.ListenAndServe(*listen_spec, nil)
2019-10-25 17:16:24 +08:00
}