Changes configuration for kube api to use gRPC

This commit is contained in:
Doug Smith
2019-02-12 10:24:00 -05:00
committed by dougbtv
parent 3a9cf4a9a2
commit 3a489263ea

View File

@@ -482,6 +482,10 @@ func GetK8sClient(kubeconfig string, kubeClient KubeClient) (KubeClient, error)
return nil, nil
}
// Specify that we use gRPC
config.AcceptContentTypes = "application/vnd.kubernetes.protobuf,application/json"
config.ContentType = "application/vnd.kubernetes.protobuf"
// creates the clientset
client, err := kubernetes.NewForConfig(config)
if err != nil {