how to fix "helm go pkg: err: context deadline exceeded"

4/1/2019

I'm trying helm go pkg, below error seen when run the code:

2019/04/01 02:30:31 err: context deadline exceeded exit status 1

Helm Version:

# helm version
Client: &version.Version{SemVer:"v2.13.0-rc.2", GitCommit:"b0d4c9eb82e036c52d130fcb031e788dffe5a5dd", GitTreeState:"clean"}
Server: &version.Version{SemVer:"v2.13.0-rc.2", GitCommit:"b0d4c9eb82e036c52d130fcb031e788dffe5a5dd", GitTreeState:"clean"}

K8s version:

kubectl version
Client Version: version.Info{Major:"1", Minor:"10", GitVersion:"v1.10.4", GitCommit:"5ca598b4ba5abb89bb773071ce452e33fb66339d", GitTreeState:"clean", BuildDate:"2018-06-06T08:13:03Z", GoVersion:"go1.9.3", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"10", GitVersion:"v1.10.4", GitCommit:"5ca598b4ba5abb89bb773071ce452e33fb66339d", GitTreeState:"clean", BuildDate:"2018-06-06T08:00:59Z", GoVersion:"go1.9.3", Compiler:"gc", Platform:"linux/amd64"}
package main

import (
    "log"
    "k8s.io/helm/pkg/helm"
)

const (
    tillerHost = "127.0.0.1:44134"
)

func main() {
    helmClient := helm.NewClient(helm.Host(tillerHost), helm.ConnectTimeout(30))
    _, err := helmClient.GetVersion()
    if err != nil {
        log.Fatalf("err: %v", err)
    }
}
-- Yunzhi Shi
go
kubernetes-helm

0 Answers