From d96abf8552bded7bb7dd02ba19443c6adfdbb980 Mon Sep 17 00:00:00 2001 From: dovholuknf <46322585+dovholuknf@users.noreply.github.com> Date: Mon, 25 Sep 2023 11:49:46 -0400 Subject: [PATCH] fix ALPN api port and remove build --- CHANGELOG.md | 2 +- ziti/cmd/edge/quickstart.go | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5edb8f5b7..5c462bdb8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,7 +23,7 @@ Example Usage: ``` - build/ziti edge quickstart \ + ziti edge quickstart \ --ctrl-address potato \ --ctrl-port 12345 \ --router-address avacado \ diff --git a/ziti/cmd/edge/quickstart.go b/ziti/cmd/edge/quickstart.go index b016284ca..23e0d96d9 100644 --- a/ziti/cmd/edge/quickstart.go +++ b/ziti/cmd/edge/quickstart.go @@ -59,7 +59,7 @@ func NewQuickStartCmd(out io.Writer, errOut io.Writer, context context.Context) cmd := &cobra.Command{ Use: "quickstart", Short: "runs a Controller and Router in quickstart mode", - Long: "runs a Controller and Router in quickstart mode. A totally ephemeral network only valid while running.", + Long: `runs a Controller and Router in quickstart mode. By default, this will create a totally ephemeral network, only valid while running.`, Run: func(cmd *cobra.Command, args []string) { options.out = out options.errOut = errOut @@ -70,7 +70,7 @@ func NewQuickStartCmd(out io.Writer, errOut io.Writer, context context.Context) cmd.Flags().StringVarP(&options.Password, "password", "p", "", "Password to use for authenticating to the Ziti Edge Controller. default: admin") cmd.Flags().BoolVar(&options.Persistent, "persistent", false, "Prevents the environment from being destroyed when shutting down. default: false") - cmd.Flags().BoolVar(&options.AlreadyInitialized, "already-initialized", false, "Specifies the PKI does not need to be created and the db does not need to be initialized. default: false") + cmd.Flags().BoolVar(&options.AlreadyInitialized, "already-initialized", false, "Specifies the PKI does not need to be created and the db does not need to be initialized. Recommended to be combined with --persistent. If --persistent is not specified the environment will be destroyed on shutdown! default: false") cmd.Flags().StringVar(&options.Home, "home", "", "Sets the directory the environment should be installed into. defaults to a temporary directory") cmd.Flags().StringVar(&options.ControllerAddress, "ctrl-address", "", "Sets the advertised address for the control plane and API") @@ -101,12 +101,14 @@ func (o *QuickstartOpts) run(ctx context.Context) { } if o.ControllerPort > 0 { _ = os.Setenv(constants.CtrlAdvertisedPortVarName, strconv.Itoa(int(o.ControllerPort))) + _ = os.Setenv(constants.CtrlEdgeAdvertisedPortVarName, strconv.Itoa(int(o.ControllerPort))) } if o.RouterAddress != "" { _ = os.Setenv(constants.ZitiEdgeRouterAdvertisedAddressVarName, o.RouterAddress) } if o.RouterPort > 0 { _ = os.Setenv(constants.ZitiEdgeRouterPortVarName, strconv.Itoa(int(o.RouterPort))) + _ = os.Setenv(constants.ZitiEdgeRouterListenerBindPortVarName, strconv.Itoa(int(o.RouterPort))) } if o.Username == "" { o.Username = "admin"