From 6cf483bf37d25aae837242c43644ebbc2de07f50 Mon Sep 17 00:00:00 2001 From: Jon Ayers Date: Wed, 15 Jun 2022 12:54:01 -0500 Subject: [PATCH] fix: allow server startup without tunnel (#2380) - Previously, specifying 'no' to the tunnel prompt just killed the process. It should be possible to start the server without a tunnel and not have the process killed. --- cli/server.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cli/server.go b/cli/server.go index b69c6c5c83..6a68a07a5d 100644 --- a/cli/server.go +++ b/cli/server.go @@ -192,9 +192,13 @@ func server() *cobra.Command { Text: "Would you like to start a tunnel for simple setup?", IsConfirm: true, }) - if errors.Is(err, cliui.Canceled) { + + if err != nil && !errors.Is(err, cliui.Canceled) { return err } + + // Don't tunnel if the user specifies no tunnel. + tunnel = !errors.Is(err, cliui.Canceled) } if err == nil { devTunnel, devTunnelErrChan, err = devtunnel.New(ctxTunnel, logger.Named("devtunnel"))