mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-20 01:23:48 +00:00
Hollow-node should use separate client for heartbeats.
This commit is contained in:
@@ -48,19 +48,13 @@ type HollowKubelet struct {
|
||||
}
|
||||
|
||||
func NewHollowKubelet(
|
||||
nodeName string,
|
||||
flags *options.KubeletFlags,
|
||||
config *kubeletconfig.KubeletConfiguration,
|
||||
client *clientset.Clientset,
|
||||
heartbeatClient *clientset.Clientset,
|
||||
cadvisorInterface cadvisor.Interface,
|
||||
dockerClientConfig *dockershim.ClientConfig,
|
||||
kubeletPort, kubeletReadOnlyPort int,
|
||||
containerManager cm.ContainerManager,
|
||||
maxPods int, podsPerCore int,
|
||||
) *HollowKubelet {
|
||||
// -----------------
|
||||
// Static config
|
||||
// -----------------
|
||||
f, c := GetHollowKubeletConfig(nodeName, kubeletPort, kubeletReadOnlyPort, maxPods, podsPerCore)
|
||||
|
||||
containerManager cm.ContainerManager) *HollowKubelet {
|
||||
// -----------------
|
||||
// Injected objects
|
||||
// -----------------
|
||||
@@ -69,7 +63,7 @@ func NewHollowKubelet(
|
||||
volumePlugins = append(volumePlugins, projected.ProbeVolumePlugins()...)
|
||||
d := &kubelet.Dependencies{
|
||||
KubeClient: client,
|
||||
HeartbeatClient: client,
|
||||
HeartbeatClient: heartbeatClient,
|
||||
DockerClientConfig: dockerClientConfig,
|
||||
CAdvisorInterface: cadvisorInterface,
|
||||
Cloud: nil,
|
||||
@@ -84,8 +78,8 @@ func NewHollowKubelet(
|
||||
}
|
||||
|
||||
return &HollowKubelet{
|
||||
KubeletFlags: f,
|
||||
KubeletConfiguration: c,
|
||||
KubeletFlags: flags,
|
||||
KubeletConfiguration: config,
|
||||
KubeletDeps: d,
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user