Skip to content

Commit

Permalink
Merge pull request #43 from linki/update-deps2
Browse files Browse the repository at this point in the history
Update client-go to ~4.0.0
  • Loading branch information
linki authored Oct 11, 2017
2 parents a7ae894 + 1b19c6e commit 6be8d35
Show file tree
Hide file tree
Showing 3,503 changed files with 549,555 additions and 367,725 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
9 changes: 5 additions & 4 deletions chaoskube/chaoskube.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,13 @@ import (
"fmt"
"math/rand"

log "github.com/Sirupsen/logrus"
log "github.com/sirupsen/logrus"

metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/apimachinery/pkg/selection"
"k8s.io/client-go/kubernetes"
"k8s.io/client-go/pkg/api/v1"
"k8s.io/client-go/pkg/labels"
"k8s.io/client-go/pkg/selection"
)

// Chaoskube represents an instance of chaoskube
Expand Down Expand Up @@ -59,7 +60,7 @@ func New(client kubernetes.Interface, labels, annotations, namespaces labels.Sel
// Candidates returns the list of pods that are available for termination.
// It returns all pods matching the label selector and at least one namespace.
func (c *Chaoskube) Candidates() ([]v1.Pod, error) {
listOptions := v1.ListOptions{LabelSelector: c.Labels.String()}
listOptions := metav1.ListOptions{LabelSelector: c.Labels.String()}

podList, err := c.Client.Core().Pods(v1.NamespaceAll).List(listOptions)
if err != nil {
Expand Down
5 changes: 3 additions & 2 deletions chaoskube/chaoskube_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@ import (
"strings"
"testing"

metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/client-go/kubernetes/fake"
"k8s.io/client-go/pkg/api/v1"
"k8s.io/client-go/pkg/labels"
)

var logOutput = bytes.NewBuffer([]byte{})
Expand Down Expand Up @@ -301,7 +302,7 @@ func validateLog(t *testing.T, msg string) {

func newPod(namespace, name string) v1.Pod {
pod := v1.Pod{
ObjectMeta: v1.ObjectMeta{
ObjectMeta: metav1.ObjectMeta{
Namespace: namespace,
Name: name,
Labels: map[string]string{
Expand Down
Loading

0 comments on commit 6be8d35

Please sign in to comment.