package mirko | |
import ( | |
"github.com/golang/glog" | |
"k8s.io/client-go/kubernetes" | |
"k8s.io/client-go/rest" | |
) | |
func (m *Mirko) kubernetesConnect() { | |
config, err := rest.InClusterConfig() | |
if err != nil { | |
glog.Errorf("mirko.KubernetesClientSet: %v", err) | |
return | |
} | |
clientset, err := kubernetes.NewForConfig(config) | |
if err != nil { | |
glog.Errorf("kubernetes.NewForConfig: %v", err) | |
return | |
} | |
m.kubernetesCS = clientset | |
} |