diff --git a/pkg/cmd/run.go b/pkg/cmd/run.go index c5bafcfa0..9880f2668 100644 --- a/pkg/cmd/run.go +++ b/pkg/cmd/run.go @@ -28,8 +28,12 @@ func init() { RunCmd.Flags().String("totp-account-name", "", "") RunCmd.Flags().Bool("enable-webserver", false, "enable webserver") RunCmd.Flags().Bool("enable-web-server", false, "legacy option, this is renamed to --enable-webserver") - RunCmd.Flags().String("cpu-profile", "", "cpu profile") RunCmd.Flags().String("webserver-bind", ":8080", "webserver binding") + + RunCmd.Flags().Bool("enable-grpc", false, "enable grpc server") + RunCmd.Flags().String("grpc-bind", ":6688", "grpc server binding") + + RunCmd.Flags().String("cpu-profile", "", "cpu profile") RunCmd.Flags().Bool("setup", false, "use setup mode") RootCmd.AddCommand(RunCmd) } @@ -40,7 +44,7 @@ var RunCmd = &cobra.Command{ // SilenceUsage is an option to silence usage when an error occurs. SilenceUsage: true, - RunE: run, + RunE: run, } func runSetup(baseCtx context.Context, userConfig *bbgo.Config, enableApiServer bool) error { diff --git a/pkg/grpc/server.go b/pkg/grpc/server.go new file mode 100644 index 000000000..fad3a9757 --- /dev/null +++ b/pkg/grpc/server.go @@ -0,0 +1,5 @@ +package grpc + + + +