diff --git a/internal/cli/requestor.go b/internal/cli/requestor.go index a2762b2..5b95b90 100644 --- a/internal/cli/requestor.go +++ b/internal/cli/requestor.go @@ -24,8 +24,14 @@ func newRequestor(ccs *components.Components) (jw.Model, error) { } cfg := ccs.Config.Server() + scheme := "http" + + if cfg.TLS != nil { + scheme += "s" + } + endpoint := &requestor.Endpoint{ - URL: fmt.Sprintf("https://localhost:%d", cfg.Port), + URL: fmt.Sprintf("%s://localhost:%d", scheme, cfg.Port), Username: username, Password: password, }