From 8ccdd2b8bc39b1c1582bb9183fe54aa8193bc410 Mon Sep 17 00:00:00 2001 From: Luc DUZAN Date: Tue, 30 Apr 2024 15:48:53 +0200 Subject: [PATCH 1/4] Improve doc --- client/client.go | 2 +- cmd/root.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/client/client.go b/client/client.go index 36af56b..e17fb17 100644 --- a/client/client.go +++ b/client/client.go @@ -58,7 +58,7 @@ func Make(token string, baseUrl string, debug bool, key, cert, cacert string, in err := result.initKindFromApi() if err != nil { - fmt.Fprintf(os.Stderr, "Cannot init kinds from api: %s\nLet's switch to default from ctl binary\n", err) + fmt.Fprintf(os.Stderr, "Cannot access the openapi: %s\nSince the CLI can't access the open API, the list of Kinds reflects the most recent ones available at the time of the CLI's release (and not the latest ones overall)\n", err) result.kinds = schema.DefaultKind() } diff --git a/cmd/root.go b/cmd/root.go index 586157b..8968658 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -24,9 +24,9 @@ func apiClient() *client.Client { var rootCmd = &cobra.Command{ Use: "conduktor", Short: "Command line tools for conduktor", - Long: `You need to define the CDK_TOKEN and CDK_BASE_URL environment variables to use this tool. -You can also use the CDK_KEY,CDK_CERT, CDK_CACERT to use a certificate for tls authentication. -If you have an untrusted certificate you can use the CDK_INSECURE=true variable to disable tls verification or set CDK_CACERT`, + Long: `Make sure you've set the environment variables CDK_TOKEN (generated from Console) and CDK_BASE_URL. +Additionally, you can configure client TLS authentication by providing your certificate paths in CDK_KEY and CDK_CERT. +For the server TLS authentication, you can either not check the certificate by setting CDK_INSECURE=true, or provide your own certificate authority using CDK_CACERT.`, PersistentPreRun: func(cmd *cobra.Command, args []string) { if *debug { apiClient().ActivateDebug() From ef79ed53b2ba643d0f44bc90925e49aa0828f2b0 Mon Sep 17 00:00:00 2001 From: LUC DUZAN Date: Tue, 30 Apr 2024 16:34:00 +0200 Subject: [PATCH 2/4] Update cmd/root.go Co-authored-by: Stu-conduktor <122447122+Stu-conduktor@users.noreply.github.com> --- cmd/root.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/root.go b/cmd/root.go index 8968658..244634d 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -26,7 +26,7 @@ var rootCmd = &cobra.Command{ Short: "Command line tools for conduktor", Long: `Make sure you've set the environment variables CDK_TOKEN (generated from Console) and CDK_BASE_URL. Additionally, you can configure client TLS authentication by providing your certificate paths in CDK_KEY and CDK_CERT. -For the server TLS authentication, you can either not check the certificate by setting CDK_INSECURE=true, or provide your own certificate authority using CDK_CACERT.`, +For the server TLS authentication, you can either ignore the certificate by setting CDK_INSECURE=true, or provide your own certificate authority using CDK_CACERT.`, PersistentPreRun: func(cmd *cobra.Command, args []string) { if *debug { apiClient().ActivateDebug() From ca964243f4b01f1cb7ef222db3f6e0febcd4bc0b Mon Sep 17 00:00:00 2001 From: LUC DUZAN Date: Tue, 30 Apr 2024 17:28:35 +0200 Subject: [PATCH 3/4] Update cmd/root.go Co-authored-by: Stu-conduktor <122447122+Stu-conduktor@users.noreply.github.com> --- cmd/root.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/root.go b/cmd/root.go index 244634d..4fb8a35 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -26,7 +26,7 @@ var rootCmd = &cobra.Command{ Short: "Command line tools for conduktor", Long: `Make sure you've set the environment variables CDK_TOKEN (generated from Console) and CDK_BASE_URL. Additionally, you can configure client TLS authentication by providing your certificate paths in CDK_KEY and CDK_CERT. -For the server TLS authentication, you can either ignore the certificate by setting CDK_INSECURE=true, or provide your own certificate authority using CDK_CACERT.`, +For server TLS authentication, you can ignore the certificate by setting CDK_INSECURE=true, or provide a certificate authority using CDK_CACERT.`, PersistentPreRun: func(cmd *cobra.Command, args []string) { if *debug { apiClient().ActivateDebug() From cc7b61b59e4b56a3872903fbd85a0131c84ffa5e Mon Sep 17 00:00:00 2001 From: LUC DUZAN Date: Tue, 30 Apr 2024 17:28:45 +0200 Subject: [PATCH 4/4] Update client/client.go Co-authored-by: Stu-conduktor <122447122+Stu-conduktor@users.noreply.github.com> --- client/client.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/client.go b/client/client.go index e17fb17..d26650a 100644 --- a/client/client.go +++ b/client/client.go @@ -58,7 +58,7 @@ func Make(token string, baseUrl string, debug bool, key, cert, cacert string, in err := result.initKindFromApi() if err != nil { - fmt.Fprintf(os.Stderr, "Cannot access the openapi: %s\nSince the CLI can't access the open API, the list of Kinds reflects the most recent ones available at the time of the CLI's release (and not the latest ones overall)\n", err) + fmt.Fprintf(os.Stderr, "Cannot access the Conduktor API: %s\nTherefore, the list of Kinds reflects the most recent ones available at the time of the CLI's release (and not the latest ones overall)\n", err) result.kinds = schema.DefaultKind() }