package main

import (
	"flag"
)

func init() {
	flag.StringVar(&API_SERVERPORT, "server", "127.0.0.1:10777", "api server port")
	flag.StringVar(&CONFIG_FILE, "conf", "./service.conf", "config file")
	flag.StringVar(&DATASTORE_DIR, "datastore", "./datastore/", "datastore dir")
	flag.Parse()
}

package main

import (
	"flag"
)

func init() {
	flag.IntVar(&API_PORT, "port", 10777, "api port")
	flag.StringVar(&CONFIG_FILE, "conf", "./service.conf", "config file")
	flag.StringVar(&DATASTORE_DIR, "datastore", "./datastore/", "datastore dir")
	flag.Parse()
}

--- 
+++ 
@@ -5,7 +5,7 @@
 )
 
 func init() {
-	flag.IntVar(&API_PORT, "port", 10777, "api port")
+	flag.StringVar(&API_SERVERPORT, "server", "127.0.0.1:10777", "api server port")
 	flag.StringVar(&CONFIG_FILE, "conf", "./service.conf", "config file")
 	flag.StringVar(&DATASTORE_DIR, "datastore", "./datastore/", "datastore dir")
 	flag.Parse()
Change api port to api server port
