Skip to content

Commit

Permalink
Merge pull request #102 from dougbtv/bugfix-checkpoint-fix
Browse files Browse the repository at this point in the history
Bug 1968625: Use the default socket path in GetResourceClient when unspecified
  • Loading branch information
dougbtv committed Jun 9, 2021
2 parents 3c199d7 + f1a7981 commit f749e15
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/kubeletclient/kubeletclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ const (

// GetResourceClient returns an instance of ResourceClient interface initialized with Pod resource information
func GetResourceClient(kubeletSocket string) (types.ResourceClient, error) {
if kubeletSocket == "" {
kubeletSocket, _ = util.LocalEndpoint(defaultPodResourcesPath, podresources.Socket)
}
// If Kubelet resource API endpoint exist use that by default
// Or else fallback with checkpoint file
if hasKubeletAPIEndpoint(kubeletSocket) {
Expand Down

0 comments on commit f749e15

Please sign in to comment.