move --runtime-config to kubeapiserver
This commit is contained in:
parent
d3c1c03062
commit
8c39f8c871
|
|
@ -25,7 +25,6 @@ import (
|
||||||
"k8s.io/apiserver/pkg/admission"
|
"k8s.io/apiserver/pkg/admission"
|
||||||
"k8s.io/apiserver/pkg/server"
|
"k8s.io/apiserver/pkg/server"
|
||||||
utilfeature "k8s.io/apiserver/pkg/util/feature"
|
utilfeature "k8s.io/apiserver/pkg/util/feature"
|
||||||
utilflag "k8s.io/apiserver/pkg/util/flag"
|
|
||||||
|
|
||||||
// add the generic feature gates
|
// add the generic feature gates
|
||||||
_ "k8s.io/apiserver/pkg/features"
|
_ "k8s.io/apiserver/pkg/features"
|
||||||
|
|
@ -53,7 +52,6 @@ type ServerRunOptions struct {
|
||||||
MaxRequestsInFlight int
|
MaxRequestsInFlight int
|
||||||
MaxMutatingRequestsInFlight int
|
MaxMutatingRequestsInFlight int
|
||||||
MinRequestTimeout int
|
MinRequestTimeout int
|
||||||
RuntimeConfig utilflag.ConfigurationMap
|
|
||||||
TargetRAMMB int
|
TargetRAMMB int
|
||||||
WatchCacheSizes []string
|
WatchCacheSizes []string
|
||||||
}
|
}
|
||||||
|
|
@ -72,7 +70,6 @@ func NewServerRunOptions() *ServerRunOptions {
|
||||||
MaxRequestsInFlight: defaults.MaxRequestsInFlight,
|
MaxRequestsInFlight: defaults.MaxRequestsInFlight,
|
||||||
MaxMutatingRequestsInFlight: defaults.MaxMutatingRequestsInFlight,
|
MaxMutatingRequestsInFlight: defaults.MaxMutatingRequestsInFlight,
|
||||||
MinRequestTimeout: defaults.MinRequestTimeout,
|
MinRequestTimeout: defaults.MinRequestTimeout,
|
||||||
RuntimeConfig: make(utilflag.ConfigurationMap),
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -195,12 +192,6 @@ func (s *ServerRunOptions) AddUniversalFlags(fs *pflag.FlagSet) {
|
||||||
"handler, which picks a randomized value above this number as the connection timeout, "+
|
"handler, which picks a randomized value above this number as the connection timeout, "+
|
||||||
"to spread out load.")
|
"to spread out load.")
|
||||||
|
|
||||||
fs.Var(&s.RuntimeConfig, "runtime-config", ""+
|
|
||||||
"A set of key=value pairs that describe runtime configuration that may be passed "+
|
|
||||||
"to apiserver. apis/<groupVersion> key can be used to turn on/off specific api versions. "+
|
|
||||||
"apis/<groupVersion>/<resource> can be used to turn on/off specific resources. api/all and "+
|
|
||||||
"api/legacy are special keys to control all and legacy api versions respectively.")
|
|
||||||
|
|
||||||
fs.StringSliceVar(&s.WatchCacheSizes, "watch-cache-sizes", s.WatchCacheSizes, ""+
|
fs.StringSliceVar(&s.WatchCacheSizes, "watch-cache-sizes", s.WatchCacheSizes, ""+
|
||||||
"List of watch cache sizes for every resource (pods, nodes, etc.), comma separated. "+
|
"List of watch cache sizes for every resource (pods, nodes, etc.), comma separated. "+
|
||||||
"The individual override format: resource#size, where size is a number. It takes effect "+
|
"The individual override format: resource#size, where size is a number. It takes effect "+
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue