Skip to content

Commit c0ae026

Browse files
authored
docs: Remove region mentions (#50)
In most cases drop in replacement with the word `platform` Signed-off-by: Marc Lopez <marc5.12@outlook.com>
1 parent 7d63ff8 commit c0ae026

File tree

160 files changed

+184
-333
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

160 files changed

+184
-333
lines changed

build/errcheck-exclusions.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,5 @@ github.com/spf13/cobra.MarkFlagRequired
44
github.com/spf13/cobra.MarkFlagFilename
55
github.com/spf13/cobra.MarkFlagFilename
66
(*github.com/spf13/cobra.Command).Help
7-
(*github.com/spf13/viper.Viper).BindPFlags
7+
(*github.com/spf13/viper.Viper).BindPFlags
8+
(*github.com/spf13/pflag.FlagSet).MarkHidden

cmd/deployment/elasticsearch/list.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ Read all the simple query string syntax in https://www.elastic.co/guide/en/elast
4545

4646
var listElasticsearchCmd = &cobra.Command{
4747
Use: "list",
48-
Short: "Returns the list of Elasticsearch clusters for a region",
48+
Short: "Returns the list of Elasticsearch clusters",
4949
Example: elasticSearchQueryExamples,
5050
PreRunE: cobra.MaximumNArgs(0),
5151
RunE: func(cmd *cobra.Command, args []string) error {

cmd/platform/allocator/list.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ import (
3030

3131
const (
3232
allocatorFilterCmdMessage = `Post-query filter out allocators based on metadata tags, for instance 'instanceType:i3.large'`
33-
allocatorListMessage = `Returns all allocators that have instances or are connected in the region. Use --all flag or --output json to show all. Use --query to match any of the allocators properties.`
33+
allocatorListMessage = `Returns all allocators that have instances or are connected to the platform. Use --all flag or --output json to show all. Use --query to match any of the allocators properties.`
3434
allocatorQueryExample = `
3535
3636
Query examples:
@@ -79,7 +79,7 @@ func listAllocators(cmd *cobra.Command, args []string) error {
7979
}
8080

8181
if cmd.Flag("output").Value.String() != "json" && !allFlag {
82-
fmt.Printf("Showing allocators that have instances or are connected in the region. Use --all flag or --output json to show all\n")
82+
fmt.Printf("Showing allocators that have instances or are connected in the platform. Use --all flag or --output json to show all\n")
8383
}
8484

8585
return ecctl.Get().Formatter.Format(filepath.Join("allocator", templateName), a)

cmd/platform/constructor/command.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import (
2828
)
2929

3030
const (
31-
constructorListMessage = `Returns all of the constructors in the region`
31+
constructorListMessage = `Returns all of the constructors in the platform`
3232
constructorShowMessage = `Returns information about the constructor with given ID`
3333
constructorMaintenanceMessage = `Sets/un-sets a constructor's maintenance mode`
3434
)

cmd/platform/proxy/command.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import (
2828
)
2929

3030
const (
31-
proxyListMessage = `Returns all of the proxies in the region`
31+
proxyListMessage = `Returns all of the proxies in the platform`
3232
proxyShowMessage = `Returns information about the proxy with given id`
3333
)
3434

cmd/platform/proxy/filteredgroup/list.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import (
2727
)
2828

2929
const (
30-
filteredGroupsUse = `Returns all proxies filtered groups in the region`
30+
filteredGroupsUse = `Returns all proxies filtered groups in the platform`
3131
)
3232

3333
func listProxyFilteredGroups(cmd *cobra.Command, args []string) error {

cmd/root.go

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -99,14 +99,10 @@ func Execute(v ecctl.VersionInfo) int {
9999

100100
func init() {
101101
RootCmd.PersistentFlags().String("config", "config", "Config name, used to have multiple configs in $HOME/.ecctl/<env>")
102-
RootCmd.PersistentFlags().String("host", "https://api.elastic-cloud.com", "Base URL to use")
102+
RootCmd.PersistentFlags().String("host", "", "Base URL to use")
103103
RootCmd.PersistentFlags().String("user", "", "Username to use to authenticate (If empty will look for EC_USER environment variable)")
104104
RootCmd.PersistentFlags().String("pass", "", "Password to use to authenticate (If empty will look for EC_PASS environment variable)")
105105
RootCmd.PersistentFlags().String("apikey", "", "API key to use to authenticate (If empty will look for EC_APIKEY environment variable)")
106-
RootCmd.PersistentFlags().String("region", "", "Elastic Cloud region")
107-
RootCmd.Flag("region").Annotations = map[string][]string{
108-
cobra.BashCompCustom: {"__ecctl_valid_regions"},
109-
}
110106
RootCmd.PersistentFlags().Bool("verbose", false, "Enable verbose mode")
111107
RootCmd.PersistentFlags().String("output", "text", "Output format [text|json]")
112108
RootCmd.PersistentFlags().Bool("force", false, "Do not ask for confirmation")
@@ -117,6 +113,13 @@ func init() {
117113
RootCmd.PersistentFlags().Bool("insecure", false, "Skips all TLS validation")
118114
RootCmd.PersistentFlags().BoolP("quiet", "q", false, "Suppresses the configuration file used for the run, if any")
119115
RootCmd.PersistentFlags().Duration("timeout", time.Second*30, "Timeout to use on all HTTP calls")
116+
RootCmd.PersistentFlags().String("region", "", "Elastic Cloud region")
117+
RootCmd.Flag("region").Annotations = map[string][]string{
118+
cobra.BashCompCustom: {"__ecctl_valid_regions"},
119+
}
120+
// Remove this line after ESS Public API is available.
121+
RootCmd.PersistentFlags().MarkHidden("region")
122+
120123
defaultViper.BindPFlags(RootCmd.PersistentFlags())
121124
}
122125

docs/ecctl.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,13 @@ Elastic Cloud Control
1414
--force Do not ask for confirmation
1515
--format string Formats the output using a Go template
1616
-h, --help help for ecctl
17-
--host string Base URL to use (default "https://api.elastic-cloud.com")
17+
--host string Base URL to use
1818
--insecure Skips all TLS validation
1919
--message string A message to set on cluster operation
2020
--output string Output format [text|json] (default "text")
2121
--pass string Password to use to authenticate (If empty will look for EC_PASS environment variable)
2222
--pprof Enables pprofing and saves the profile to pprof-20060102150405
2323
-q, --quiet Suppresses the configuration file used for the run, if any
24-
--region string Elastic Cloud region
2524
--timeout duration Timeout to use on all HTTP calls (default 30s)
2625
--trace Enables tracing saves the trace to trace-20060102150405
2726
--user string Username to use to authenticate (If empty will look for EC_USER environment variable)

docs/ecctl_auth.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,13 @@ ecctl auth [flags]
2323
--config string Config name, used to have multiple configs in $HOME/.ecctl/<env> (default "config")
2424
--force Do not ask for confirmation
2525
--format string Formats the output using a Go template
26-
--host string Base URL to use (default "https://api.elastic-cloud.com")
26+
--host string Base URL to use
2727
--insecure Skips all TLS validation
2828
--message string A message to set on cluster operation
2929
--output string Output format [text|json] (default "text")
3030
--pass string Password to use to authenticate (If empty will look for EC_PASS environment variable)
3131
--pprof Enables pprofing and saves the profile to pprof-20060102150405
3232
-q, --quiet Suppresses the configuration file used for the run, if any
33-
--region string Elastic Cloud region
3433
--timeout duration Timeout to use on all HTTP calls (default 30s)
3534
--trace Enables tracing saves the trace to trace-20060102150405
3635
--user string Username to use to authenticate (If empty will look for EC_USER environment variable)

docs/ecctl_auth_key.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,13 @@ ecctl auth key [flags]
2323
--config string Config name, used to have multiple configs in $HOME/.ecctl/<env> (default "config")
2424
--force Do not ask for confirmation
2525
--format string Formats the output using a Go template
26-
--host string Base URL to use (default "https://api.elastic-cloud.com")
26+
--host string Base URL to use
2727
--insecure Skips all TLS validation
2828
--message string A message to set on cluster operation
2929
--output string Output format [text|json] (default "text")
3030
--pass string Password to use to authenticate (If empty will look for EC_PASS environment variable)
3131
--pprof Enables pprofing and saves the profile to pprof-20060102150405
3232
-q, --quiet Suppresses the configuration file used for the run, if any
33-
--region string Elastic Cloud region
3433
--timeout duration Timeout to use on all HTTP calls (default 30s)
3534
--trace Enables tracing saves the trace to trace-20060102150405
3635
--user string Username to use to authenticate (If empty will look for EC_USER environment variable)

0 commit comments

Comments
 (0)