mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-27 05:04:52 +00:00
add default for loggingconfiguration struct
This commit is contained in:
@@ -100,6 +100,9 @@ func Funcs(codecs runtimeserializer.CodecFactory) []interface{} {
|
||||
obj.ConfigMapAndSecretChangeDetectionStrategy = "Watch"
|
||||
obj.AllowedUnsafeSysctls = []string{}
|
||||
obj.VolumePluginDir = kubeletconfigv1beta1.DefaultVolumePluginDir
|
||||
if obj.Logging.Format == "" {
|
||||
obj.Logging.Format = "text"
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
|
@@ -49,7 +49,8 @@ iptablesMasqueradeBit: 14
|
||||
kind: KubeletConfiguration
|
||||
kubeAPIBurst: 10
|
||||
kubeAPIQPS: 5
|
||||
logging: {}
|
||||
logging:
|
||||
format: text
|
||||
makeIPTablesUtilChains: true
|
||||
maxOpenFiles: 1000000
|
||||
maxPods: 110
|
||||
|
@@ -49,7 +49,8 @@ iptablesMasqueradeBit: 14
|
||||
kind: KubeletConfiguration
|
||||
kubeAPIBurst: 10
|
||||
kubeAPIQPS: 5
|
||||
logging: {}
|
||||
logging:
|
||||
format: text
|
||||
makeIPTablesUtilChains: true
|
||||
maxOpenFiles: 1000000
|
||||
maxPods: 110
|
||||
|
@@ -21,6 +21,7 @@ import (
|
||||
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
kruntime "k8s.io/apimachinery/pkg/runtime"
|
||||
componentbaseconfigv1alpha1 "k8s.io/component-base/config/v1alpha1"
|
||||
kubeletconfigv1beta1 "k8s.io/kubelet/config/v1beta1"
|
||||
// TODO: Cut references to k8s.io/kubernetes, eventually there should be none from this package
|
||||
"k8s.io/kubernetes/pkg/kubelet/qos"
|
||||
@@ -233,4 +234,6 @@ func SetDefaults_KubeletConfiguration(obj *kubeletconfigv1beta1.KubeletConfigura
|
||||
if obj.VolumePluginDir == "" {
|
||||
obj.VolumePluginDir = DefaultVolumePluginDir
|
||||
}
|
||||
// Use the Default LoggingConfiguration option
|
||||
componentbaseconfigv1alpha1.RecommendedLoggingConfiguration(&obj.Logging)
|
||||
}
|
||||
|
Reference in New Issue
Block a user