Fix defaults for MaxPods and MaxOpenFiles.
Fix go formatting and docs.
This commit is contained in:
@@ -197,27 +197,29 @@ func NewKubeletServer() *KubeletServer {
|
||||
MaxContainerCount: 100,
|
||||
MaxPerPodContainerCount: 2,
|
||||
MaxOpenFiles: 1000000,
|
||||
MaxPods: 40,
|
||||
MinimumGCAge: 1 * time.Minute,
|
||||
NetworkPluginDir: "/usr/libexec/kubernetes/kubelet-plugins/net/exec/",
|
||||
NetworkPluginName: "",
|
||||
NodeStatusUpdateFrequency: 10 * time.Second,
|
||||
OOMScoreAdj: qos.KubeletOOMScoreAdj,
|
||||
PodInfraContainerImage: dockertools.PodInfraContainerImage,
|
||||
Port: ports.KubeletPort,
|
||||
ReadOnlyPort: ports.KubeletReadOnlyPort,
|
||||
RegisterNode: true, // will be ignored if no apiserver is configured
|
||||
RegisterSchedulable: true,
|
||||
RegistryBurst: 10,
|
||||
ResourceContainer: "/kubelet",
|
||||
RktPath: "",
|
||||
RktStage1Image: "",
|
||||
RootDirectory: defaultRootDir,
|
||||
SerializeImagePulls: true,
|
||||
SyncFrequency: 10 * time.Second,
|
||||
SystemContainer: "",
|
||||
ReconcileCIDR: true,
|
||||
KubeAPIQPS: 5.0,
|
||||
KubeAPIBurst: 10,
|
||||
Port: ports.KubeletPort,
|
||||
ReadOnlyPort: ports.KubeletReadOnlyPort,
|
||||
RegisterNode: true, // will be ignored if no apiserver is configured
|
||||
RegisterSchedulable: true,
|
||||
RegistryBurst: 10,
|
||||
ResourceContainer: "/kubelet",
|
||||
RktPath: "",
|
||||
RktStage1Image: "",
|
||||
RootDirectory: defaultRootDir,
|
||||
SerializeImagePulls: true,
|
||||
StreamingConnectionIdleTimeout: 5 * time.Minute,
|
||||
SyncFrequency: 10 * time.Second,
|
||||
SystemContainer: "",
|
||||
ReconcileCIDR: true,
|
||||
KubeAPIQPS: 5.0,
|
||||
KubeAPIBurst: 10,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -315,7 +317,7 @@ func (s *KubeletServer) AddFlags(fs *pflag.FlagSet) {
|
||||
fs.StringVar(&s.RktStage1Image, "rkt-stage1-image", s.RktStage1Image, "image to use as stage1. Local paths and http/https URLs are supported. If empty, the 'stage1.aci' in the same directory as '--rkt-path' will be used")
|
||||
fs.StringVar(&s.SystemContainer, "system-container", s.SystemContainer, "Optional resource-only container in which to place all non-kernel processes that are not already in a container. Empty for no container. Rolling back the flag requires a reboot. (Default: \"\").")
|
||||
fs.BoolVar(&s.ConfigureCBR0, "configure-cbr0", s.ConfigureCBR0, "If true, kubelet will configure cbr0 based on Node.Spec.PodCIDR.")
|
||||
fs.IntVar(&s.MaxPods, "max-pods", 40, "Number of Pods that can run on this Kubelet.")
|
||||
fs.IntVar(&s.MaxPods, "max-pods", s.MaxPods, "Number of Pods that can run on this Kubelet.")
|
||||
fs.StringVar(&s.DockerExecHandlerName, "docker-exec-handler", s.DockerExecHandlerName, "Handler to use when executing a command in a container. Valid values are 'native' and 'nsenter'. Defaults to 'native'.")
|
||||
fs.StringVar(&s.PodCIDR, "pod-cidr", "", "The CIDR to use for pod IP addresses, only used in standalone mode. In cluster mode, this is obtained from the master.")
|
||||
fs.StringVar(&s.ResolverConfig, "resolv-conf", kubelet.ResolvConfDefault, "Resolver configuration file used as the basis for the container DNS resolution configuration.")
|
||||
@@ -324,7 +326,7 @@ func (s *KubeletServer) AddFlags(fs *pflag.FlagSet) {
|
||||
fs.BoolVar(&s.ReallyCrashForTesting, "really-crash-for-testing", s.ReallyCrashForTesting, "If true, when panics occur crash. Intended for testing.")
|
||||
fs.Float64Var(&s.ChaosChance, "chaos-chance", s.ChaosChance, "If > 0.0, introduce random client errors and latency. Intended for testing. [default=0.0]")
|
||||
fs.BoolVar(&s.Containerized, "containerized", s.Containerized, "Experimental support for running kubelet in a container. Intended for testing. [default=false]")
|
||||
fs.Uint64Var(&s.MaxOpenFiles, "max-open-files", 1000000, "Number of files that can be opened by Kubelet process. [default=1000000]")
|
||||
fs.Uint64Var(&s.MaxOpenFiles, "max-open-files", s.MaxOpenFiles, "Number of files that can be opened by Kubelet process. [default=1000000]")
|
||||
fs.BoolVar(&s.ReconcileCIDR, "reconcile-cidr", s.ReconcileCIDR, "Reconcile node CIDR with the CIDR specified by the API server. No-op if register-node or configure-cbr0 is false. [default=true]")
|
||||
fs.BoolVar(&s.RegisterSchedulable, "register-schedulable", s.RegisterSchedulable, "Register the node as schedulable. No-op if register-node is false. [default=true]")
|
||||
fs.Float32Var(&s.KubeAPIQPS, "kube-api-qps", s.KubeAPIQPS, "QPS to use while talking with kubernetes apiserver")
|
||||
|
||||
Reference in New Issue
Block a user