Skip to content

Commit

Permalink
Merge pull request #1956 from bjorand/version_flag
Browse files Browse the repository at this point in the history
remove broken --version flag, replace by version command
  • Loading branch information
k8s-ci-robot committed Jan 24, 2023
2 parents 1cda0bf + 57a196b commit bc7b5b6
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 67 deletions.
1 change: 0 additions & 1 deletion docs/cli-arguments.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ Flags:
--total-shards int The total number of shards. Sharding is disabled when total shards is set to 1. (default 1)
--use-apiserver-cache Sets resourceVersion=0 for ListWatch requests, using cached resources from the apiserver instead of an etcd quorum read.
-v, --v Level number for the log level verbosity
--version kube-state-metrics build version information
--vmodule moduleSpec comma-separated list of pattern=N settings for file-filtered logging
Use "kube-state-metrics [command] --help" for more information about a command.
Expand Down
2 changes: 0 additions & 2 deletions pkg/options/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ type Options struct {
TelemetryPort int `yaml:"telemetry_port"`
TotalShards int `yaml:"total_shards"`
UseAPIServerCache bool `yaml:"use_api_server_cache"`
Version bool `yaml:"version"`

Config string

Expand Down Expand Up @@ -123,7 +122,6 @@ func (o *Options) AddFlags(cmd *cobra.Command) {
o.cmd.Flags().BoolVar(&o.EnableGZIPEncoding, "enable-gzip-encoding", false, "Gzip responses when requested by clients via 'Accept-Encoding: gzip' header.")
o.cmd.Flags().BoolVarP(&o.Help, "help", "h", false, "Print Help text")
o.cmd.Flags().BoolVarP(&o.UseAPIServerCache, "use-apiserver-cache", "", false, "Sets resourceVersion=0 for ListWatch requests, using cached resources from the apiserver instead of an etcd quorum read.")
o.cmd.Flags().BoolVarP(&o.Version, "version", "", false, "kube-state-metrics build version information")
o.cmd.Flags().Int32Var(&o.Shard, "shard", int32(0), "The instances shard nominal (zero indexed) within the total number of shards. (default 0)")
o.cmd.Flags().IntVar(&o.Port, "port", 8080, `Port to expose metrics on.`)
o.cmd.Flags().IntVar(&o.TelemetryPort, "telemetry-port", 8081, `Port to expose kube-state-metrics self metrics on.`)
Expand Down
64 changes: 0 additions & 64 deletions pkg/version/version.go

This file was deleted.

0 comments on commit bc7b5b6

Please sign in to comment.