Update k8s client version to 4.0.0 (#351)

Move to client-go v4.0.0 from 1.5.
This commit is contained in:
Ta-Ching Chen
2017-09-29 07:37:36 -07:00
committed by Soam Vasani
parent e4d42797e6
commit a25c167d23
66 changed files with 825 additions and 798 deletions
+4 -3
View File
@@ -29,8 +29,9 @@ import (
"github.com/gorilla/handlers"
"github.com/gorilla/mux"
log "github.com/sirupsen/logrus"
"k8s.io/client-go/1.5/kubernetes"
"k8s.io/client-go/1.5/rest"
"k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/client-go/kubernetes"
"k8s.io/client-go/rest"
)
func makelogRequestTracker() logRequestTracker {
@@ -101,7 +102,7 @@ func parseContainerString(containerID string) (string, error) {
}
func getcontainerID(kubeClient *kubernetes.Clientset, namespace, pod, container string) (string, error) {
podInfo, err := kubeClient.Core().Pods(namespace).Get(pod)
podInfo, err := kubeClient.CoreV1().Pods(namespace).Get(pod, v1.GetOptions{})
if err != nil {
log.Printf("Failed to get pod info: %v", err)
return "", err