Merge pull request #19741 from pwittrock/syncfsmetrics
Auto commit by PR queue bot
This commit is contained in:
@@ -69,6 +69,7 @@ func NewKubeletServer() *KubeletServer {
|
||||
KubeletConfiguration: componentconfig.KubeletConfiguration{
|
||||
Address: "0.0.0.0",
|
||||
CAdvisorPort: 4194,
|
||||
VolumeStatsAggPeriod: unversioned.Duration{time.Minute},
|
||||
CertDirectory: "/var/run/kubernetes",
|
||||
CgroupRoot: "",
|
||||
ConfigureCBR0: false,
|
||||
@@ -182,6 +183,7 @@ func (s *KubeletServer) AddFlags(fs *pflag.FlagSet) {
|
||||
fs.IntVar(&s.ImageGCHighThresholdPercent, "image-gc-high-threshold", s.ImageGCHighThresholdPercent, "The percent of disk usage after which image garbage collection is always run. Default: 90%")
|
||||
fs.IntVar(&s.ImageGCLowThresholdPercent, "image-gc-low-threshold", s.ImageGCLowThresholdPercent, "The percent of disk usage before which image garbage collection is never run. Lowest disk usage to garbage collect to. Default: 80%")
|
||||
fs.IntVar(&s.LowDiskSpaceThresholdMB, "low-diskspace-threshold-mb", s.LowDiskSpaceThresholdMB, "The absolute free disk space, in MB, to maintain. When disk space falls below this threshold, new pods would be rejected. Default: 256")
|
||||
fs.DurationVar(&s.VolumeStatsAggPeriod.Duration, "volume-stats-agg-period", s.VolumeStatsAggPeriod.Duration, "Specifies interval for kubelet to calculate and cache the volume disk usage for all pods and volumes. To disable volume calculations, set to 0. Default: '1m'")
|
||||
fs.StringVar(&s.NetworkPluginName, "network-plugin", s.NetworkPluginName, "<Warning: Alpha feature> The name of the network plugin to be invoked for various events in kubelet/pod lifecycle")
|
||||
fs.StringVar(&s.NetworkPluginDir, "network-plugin-dir", s.NetworkPluginDir, "<Warning: Alpha feature> The full path of the directory in which to search for network plugins")
|
||||
fs.StringVar(&s.VolumePluginDir, "volume-plugin-dir", s.VolumePluginDir, "<Warning: Alpha feature> The full path of the directory in which to search for additional third party volume plugins")
|
||||
|
@@ -180,6 +180,7 @@ func UnsecuredKubeletConfig(s *options.KubeletServer) (*KubeletConfig, error) {
|
||||
AllowPrivileged: s.AllowPrivileged,
|
||||
Auth: nil, // default does not enforce auth[nz]
|
||||
CAdvisorInterface: nil, // launches background processes, not set here
|
||||
VolumeStatsAggPeriod: s.VolumeStatsAggPeriod.Duration,
|
||||
CgroupRoot: s.CgroupRoot,
|
||||
Cloud: nil, // cloud provider might start background processes
|
||||
ClusterDNS: net.ParseIP(s.ClusterDNS),
|
||||
@@ -481,6 +482,7 @@ func SimpleKubelet(client *clientset.Clientset,
|
||||
kcfg := KubeletConfig{
|
||||
Address: net.ParseIP(address),
|
||||
CAdvisorInterface: cadvisorInterface,
|
||||
VolumeStatsAggPeriod: time.Minute,
|
||||
CgroupRoot: "",
|
||||
Cloud: cloud,
|
||||
ClusterDNS: clusterDNS,
|
||||
@@ -654,6 +656,7 @@ type KubeletConfig struct {
|
||||
Auth server.AuthInterface
|
||||
Builder KubeletBuilder
|
||||
CAdvisorInterface cadvisor.Interface
|
||||
VolumeStatsAggPeriod time.Duration
|
||||
CgroupRoot string
|
||||
Cloud cloudprovider.Interface
|
||||
ClusterDNS net.IP
|
||||
@@ -815,6 +818,7 @@ func CreateAndInitKubelet(kc *KubeletConfig) (k KubeletBootstrap, pc *config.Pod
|
||||
kc.NodeIP,
|
||||
kc.Reservation,
|
||||
kc.EnableCustomMetrics,
|
||||
kc.VolumeStatsAggPeriod,
|
||||
)
|
||||
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user