示例#1
0
func serverMain(c *cli.Context) {
	if c.Args().Present() {
		cli.ShowCommandHelpAndExit(c, "server", 1)
	}
	apiServerConfig := getServerConfig(c)
	err := server.StartServices(apiServerConfig)
	if err != nil {
		Fatalln(err)
	}
}
示例#2
0
func runServer(c *cli.Context) {
	_, err := user.Current()
	if err != nil {
		Fatalf("Unable to determine current user. Reason: %s\n", err)
	}
	apiServerConfig := getServerConfig(c)
	err = server.StartServices(apiServerConfig)
	if err != nil {
		Fatalln(err)
	}
}
示例#3
0
func runServer(c *cli.Context) {
	if c.Args().Present() {
		cli.ShowCommandHelpAndExit(c, "server", 1)
	}
	_, err := user.Current()
	if err != nil {
		Fatalf("Unable to determine current user. Reason: %s\n", err)
	}
	apiServerConfig := getServerConfig(c)
	err = server.StartServices(apiServerConfig)
	if err != nil {
		Fatalln(err)
	}
}