Skip to content

Commit

Permalink
Merge pull request kubernetes-retired#1849 from andyxning/bump_kubern…
Browse files Browse the repository at this point in the history
…etes_to_1.8

bump kubernetes to 1.9.3
  • Loading branch information
k8s-ci-robot authored Mar 29, 2018
2 parents 89ea3ac + 06daf72 commit 784a4b5
Show file tree
Hide file tree
Showing 2,022 changed files with 317,455 additions and 296,503 deletions.
1,553 changes: 1,133 additions & 420 deletions Godeps/Godeps.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ ifeq ($(INTERACTIVE), 1)
TTY=-t
endif

SUPPORTED_KUBE_VERSIONS=1.7.0-beta.2
SUPPORTED_KUBE_VERSIONS=1.9.3
TEST_NAMESPACE=heapster-e2e-tests

HEAPSTER_LDFLAGS=-w -X k8s.io/heapster/version.HeapsterVersion=$(VERSION) -X k8s.io/heapster/version.GitCommit=$(GIT_COMMIT)
Expand Down
18 changes: 7 additions & 11 deletions common/kubernetes/configs.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,14 @@ const (

func getConfigOverrides(uri *url.URL) (*kubeClientCmd.ConfigOverrides, error) {
kubeConfigOverride := kubeClientCmd.ConfigOverrides{
ClusterInfo: kubeClientCmdApi.Cluster{
APIVersion: APIVersion,
},
ClusterInfo: kubeClientCmdApi.Cluster{},
}
if len(uri.Scheme) != 0 && len(uri.Host) != 0 {
kubeConfigOverride.ClusterInfo.Server = fmt.Sprintf("%s://%s", uri.Scheme, uri.Host)
}

opts := uri.Query()

if len(opts["apiVersion"]) >= 1 {
kubeConfigOverride.ClusterInfo.APIVersion = opts["apiVersion"][0]
}

if len(opts["insecure"]) > 0 {
insecure, err := strconv.ParseBool(opts["insecure"][0])
if err != nil {
Expand Down Expand Up @@ -92,7 +86,7 @@ func GetKubeClientConfig(uri *url.URL) (*kube_rest.Config, error) {
if configOverrides.ClusterInfo.Server != "" {
kubeConfig.Host = configOverrides.ClusterInfo.Server
}
kubeConfig.GroupVersion = &schema.GroupVersion{Version: configOverrides.ClusterInfo.APIVersion}
kubeConfig.GroupVersion = &schema.GroupVersion{Version: APIVersion}
kubeConfig.Insecure = configOverrides.ClusterInfo.InsecureSkipTLSVerify
if configOverrides.ClusterInfo.InsecureSkipTLSVerify {
kubeConfig.TLSClientConfig.CAFile = ""
Expand Down Expand Up @@ -121,10 +115,12 @@ func GetKubeClientConfig(uri *url.URL) (*kube_rest.Config, error) {
}
} else {
kubeConfig = &kube_rest.Config{
Host: configOverrides.ClusterInfo.Server,
Insecure: configOverrides.ClusterInfo.InsecureSkipTLSVerify,
Host: configOverrides.ClusterInfo.Server,
TLSClientConfig: kube_rest.TLSClientConfig{
Insecure: configOverrides.ClusterInfo.InsecureSkipTLSVerify,
},
}
kubeConfig.GroupVersion = &schema.GroupVersion{Version: configOverrides.ClusterInfo.APIVersion}
kubeConfig.GroupVersion = &schema.GroupVersion{Version: APIVersion}
}
}
if len(kubeConfig.Host) == 0 {
Expand Down
3 changes: 2 additions & 1 deletion deploy/kube-config/standalone-test/heapster-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ spec:
labels:
k8s-app: heapster-test
spec:
serviceAccountName: heapster
containers:
- name: heapster-test
image: k8s.gcr.io/heapster-amd64:v1.4.2
image: k8s.gcr.io/heapster-amd64:v1.5.1
imagePullPolicy: Always
command:
- /heapster
Expand Down
12 changes: 12 additions & 0 deletions deploy/kube-config/standalone-test/heapster-rbac.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: heapster
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: system:heapster
subjects:
- kind: ServiceAccount
name: heapster
namespace: heapster-e2e-tests
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
apiVersion: v1
kind: ServiceAccount
metadata:
name: heapster
namespace: heapster-e2e-tests
1 change: 0 additions & 1 deletion docs/source-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ The following options are available:
* `inClusterConfig` - Use kube config in service accounts associated with Heapster's namespace. (default: true)
* `kubeletPort` - kubelet port to use (default: `10255`)
* `kubeletHttps` - whether to use https to connect to kubelets (default: `false`)
* `apiVersion` - API version to use to talk to Kubernetes. Defaults to the version in kubeConfig.
* `insecure` - whether to trust kubernetes certificates (default: `false`)
* `auth` - client auth file to use. Set auth if the service accounts are not usable.
* `useServiceAccount` - whether to use the service account token if one is mounted at `/var/run/secrets/kubernetes.io/serviceaccount/token` (default: `false`)
Expand Down
2 changes: 1 addition & 1 deletion events/core/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ package core
import (
"time"

kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"
)

type EventBatch struct {
Expand Down
2 changes: 1 addition & 1 deletion events/manager/manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"testing"
"time"

kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"
"k8s.io/heapster/events/core"
"k8s.io/heapster/events/util"
)
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/elasticsearch/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"time"

"github.com/golang/glog"
kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"
esCommon "k8s.io/heapster/common/elasticsearch"
event_core "k8s.io/heapster/events/core"
"k8s.io/heapster/metrics/core"
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/elasticsearch/driver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ import (
"time"

"github.com/stretchr/testify/assert"
kube_api "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
kube_api "k8s.io/client-go/pkg/api/v1"
esCommon "k8s.io/heapster/common/elasticsearch"
"k8s.io/heapster/events/core"
)
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/honeycomb/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import (
"sync"

"github.com/golang/glog"
kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"
honeycomb_common "k8s.io/heapster/common/honeycomb"
event_core "k8s.io/heapster/events/core"
)
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/honeycomb/honeycomb_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ import (
"net/url"

"github.com/stretchr/testify/assert"
kube_api "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
kube_api "k8s.io/client-go/pkg/api/v1"
honeycomb_common "k8s.io/heapster/common/honeycomb"
"k8s.io/heapster/events/core"
)
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/influxdb/influxdb.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"sync"
"time"

kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"
influxdb_common "k8s.io/heapster/common/influxdb"
"k8s.io/heapster/events/core"
metrics_core "k8s.io/heapster/metrics/core"
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/influxdb/influxdb_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ import (
"net/url"

"github.com/stretchr/testify/assert"
kube_api "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
kube_api "k8s.io/client-go/pkg/api/v1"
util "k8s.io/client-go/util/testing"
influxdb_common "k8s.io/heapster/common/influxdb"
"k8s.io/heapster/events/core"
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/kafka/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
"time"

"github.com/golang/glog"
kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"
kafka_common "k8s.io/heapster/common/kafka"
event_core "k8s.io/heapster/events/core"
"k8s.io/heapster/metrics/core"
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/kafka/driver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import (
"time"

"github.com/stretchr/testify/assert"
kube_api "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
kube_api "k8s.io/client-go/pkg/api/v1"
event_core "k8s.io/heapster/events/core"
)

Expand Down
2 changes: 1 addition & 1 deletion events/sinks/log/log_sink_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ import (
"time"

"github.com/stretchr/testify/assert"
kube_api "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
kube_api "k8s.io/client-go/pkg/api/v1"

"k8s.io/heapster/events/core"
)
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import (
"time"

"github.com/stretchr/testify/assert"
kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"

"k8s.io/heapster/events/core"
"k8s.io/heapster/events/util"
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/riemann/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (

"github.com/golang/glog"
"github.com/riemann/riemann-go-client"
kube_api "k8s.io/client-go/pkg/api/v1"
kube_api "k8s.io/api/core/v1"
riemannCommon "k8s.io/heapster/common/riemann"
"k8s.io/heapster/events/core"
)
Expand Down
2 changes: 1 addition & 1 deletion events/sinks/riemann/driver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ import (
pb "github.com/golang/protobuf/proto"
"github.com/riemann/riemann-go-client/proto"
"github.com/stretchr/testify/assert"
kube_api "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
kube_api "k8s.io/client-go/pkg/api/v1"
riemannCommon "k8s.io/heapster/common/riemann"
"k8s.io/heapster/events/core"
)
Expand Down
4 changes: 2 additions & 2 deletions events/sources/kubernetes/kubernetes_source.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ import (
"github.com/golang/glog"
"github.com/prometheus/client_golang/prometheus"

kubeapi "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
kubewatch "k8s.io/apimachinery/pkg/watch"
kubeclient "k8s.io/client-go/kubernetes"
kubev1core "k8s.io/client-go/kubernetes/typed/core/v1"
kubeapi "k8s.io/client-go/pkg/api/v1"
kubeconfig "k8s.io/heapster/common/kubernetes"
"k8s.io/heapster/events/core"
)
Expand Down Expand Up @@ -181,7 +181,7 @@ func NewKubernetesSource(uri *url.URL) (*KubernetesEventSource, error) {
if err != nil {
return nil, err
}
eventClient := kubeClient.Events(kubeapi.NamespaceAll)
eventClient := kubeClient.CoreV1().Events(kubeapi.NamespaceAll)
result := KubernetesEventSource{
localEventsBuffer: make(chan *kubeapi.Event, LocalEventsBufferSize),
stopChannel: make(chan struct{}),
Expand Down
2 changes: 1 addition & 1 deletion integration/.jenkins.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export GOBIN="$GOPATH/bin"
export PATH="$GOBIN:$PATH"

# Kubernetes version(s) to run the integration tests against.
kube_version="1.7.0-beta.2"
kube_version="1.9.3"

if ! git diff --name-only origin/master | grep -c -E "*.go|*.sh|.*yaml|Makefile" &> /dev/null; then
echo "This PR does not touch files that require integration testing. Skipping integration tests!"
Expand Down
Loading

0 comments on commit 784a4b5

Please sign in to comment.