Skip to content

Commit

Permalink
PANDARIA: update wrangler to wrangler/v3
Browse files Browse the repository at this point in the history
  • Loading branch information
GGGitBoy committed Jul 9, 2024
1 parent 62dd984 commit 2b6bd9b
Show file tree
Hide file tree
Showing 16 changed files with 1,560 additions and 108 deletions.
4 changes: 2 additions & 2 deletions Dockerfile.dapper
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ RUN zypper -n update && \

ENV GOLANG_ARCH_amd64=amd64 GOLANG_ARCH_arm=armv6l GOLANG_ARCH_arm64=arm64 GOLANG_ARCH=GOLANG_ARCH_${ARCH} \
GOPATH=/go PATH=/go/bin:/usr/local/go/bin:${PATH} SHELL=/bin/bash
RUN curl -sLf https://storage.googleapis.com/golang/go1.19.3.linux-${ARCH}.tar.gz | tar -xzf - -C /usr/local/
RUN curl -sLf https://storage.googleapis.com/golang/go1.22.0.linux-${ARCH}.tar.gz | tar -xzf - -C /usr/local/
# workaround for https://bugzilla.suse.com/show_bug.cgi?id=1183043
RUN if [ "${ARCH}" == "arm64" ]; then \
zypper -n install binutils-gold ; \
fi

RUN if [ "${ARCH}" = "amd64" ]; then \
curl -sL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s v1.40.1; \
curl -sL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s v1.59.0; \
fi
RUN curl -sL https://get.helm.sh/helm-v3.3.0-linux-${ARCH}.tar.gz | tar xvzf - -C /usr/local/bin --strip-components=1

Expand Down
4 changes: 2 additions & 2 deletions controller/tke-cluster-config-handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import (
tkev1 "github.com/cnrancher/tke-operator/pkg/apis/tke.pandaria.io/v1"
v12 "github.com/cnrancher/tke-operator/pkg/generated/controllers/tke.pandaria.io/v1"
"github.com/cnrancher/tke-operator/utils"
wranglerv1 "github.com/rancher/wrangler/v2/pkg/generated/controllers/core/v1"
"github.com/rancher/wrangler/v2/pkg/slice"
wranglerv1 "github.com/rancher/wrangler/v3/pkg/generated/controllers/core/v1"
"github.com/rancher/wrangler/v3/pkg/slice"
"github.com/sirupsen/logrus"
tcerrors "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/errors"
tkeapi "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/tke/v20180525"
Expand Down
4 changes: 3 additions & 1 deletion driver/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ import (
"fmt"
"github.com/cnrancher/tke-operator/driver/client"
"github.com/cnrancher/tke-operator/utils"
wranglerv1 "github.com/rancher/wrangler/v2/pkg/generated/controllers/core/v1"
wranglerv1 "github.com/rancher/wrangler/v3/pkg/generated/controllers/core/v1"
tccommon "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common"
v1 "k8s.io/api/core/v1"
)

// state of cluster
Expand Down Expand Up @@ -96,6 +97,7 @@ func GetCredential(secretsCache wranglerv1.SecretCache, tkeCredentialSecret stri
return nil, fmt.Errorf("error while getting tkeCredentialSecret")
}

var secret *v1.Secret
ns, name := utils.Parse(tkeCredentialSecret)
secret, err := secretsCache.Get(ns, name)
if err != nil {
Expand Down
55 changes: 27 additions & 28 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,41 +1,41 @@
module github.com/cnrancher/tke-operator

go 1.20
go 1.22.0

replace k8s.io/client-go => k8s.io/client-go v0.28.6
replace k8s.io/client-go => k8s.io/client-go v0.30.1

require (
github.com/google/uuid v1.3.0
github.com/rancher/lasso v0.0.0-20240123150939-7055397d6dfa
github.com/rancher/lasso v0.0.0-20240430201833-6f3def65ffc5
github.com/rancher/wrangler-api v0.6.1-0.20200427172631-a7c2f09b783e
github.com/rancher/wrangler/v2 v2.1.3
github.com/sirupsen/logrus v1.9.0
github.com/rancher/wrangler/v3 v3.0.0-rc2
github.com/sirupsen/logrus v1.9.3
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/as v1.0.715
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cbs v1.0.715
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.715
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cvm v1.0.715
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/tke v1.0.715
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/vpc v1.0.715
k8s.io/api v0.28.6
k8s.io/apimachinery v0.28.6
k8s.io/client-go v0.28.6
k8s.io/api v0.30.1
k8s.io/apimachinery v0.30.1
k8s.io/client-go v0.30.0
)

require (
github.com/beorn7/perks v1.0.1 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
github.com/evanphx/json-patch v5.6.0+incompatible // indirect
github.com/ghodss/yaml v1.0.0 // indirect
github.com/go-logr/logr v1.2.4 // indirect
github.com/go-logr/logr v1.4.1 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/golang/protobuf v1.5.4 // indirect
github.com/google/gnostic-models v0.6.8 // indirect
github.com/google/go-cmp v0.5.9 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/josharian/intern v1.0.0 // indirect
Expand All @@ -45,36 +45,35 @@ require (
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/onsi/ginkgo/v2 v2.9.5 // indirect
github.com/onsi/gomega v1.27.7 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/prometheus/client_golang v1.16.0 // indirect
github.com/prometheus/client_model v0.4.0 // indirect
github.com/prometheus/common v0.44.0 // indirect
github.com/prometheus/procfs v0.10.1 // indirect
github.com/rancher/wrangler v0.6.2-0.20200427172034-da9b142ae061 // indirect
github.com/spf13/pflag v1.0.5 // indirect
golang.org/x/mod v0.14.0 // indirect
golang.org/x/net v0.19.0 // indirect
golang.org/x/mod v0.17.0 // indirect
golang.org/x/net v0.24.0 // indirect
golang.org/x/oauth2 v0.10.0 // indirect
golang.org/x/sync v0.5.0 // indirect
golang.org/x/sys v0.15.0 // indirect
golang.org/x/term v0.15.0 // indirect
golang.org/x/sync v0.7.0 // indirect
golang.org/x/sys v0.19.0 // indirect
golang.org/x/term v0.19.0 // indirect
golang.org/x/text v0.14.0 // indirect
golang.org/x/time v0.3.0 // indirect
golang.org/x/tools v0.16.1 // indirect
golang.org/x/tools v0.20.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/protobuf v1.31.0 // indirect
google.golang.org/protobuf v1.33.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiextensions-apiserver v0.28.6 // indirect
k8s.io/code-generator v0.28.6 // indirect
k8s.io/gengo v0.0.0-20220902162205-c0856e24416d // indirect
k8s.io/klog/v2 v2.100.1 // indirect
k8s.io/kube-openapi v0.0.0-20230717233707-2695361300d9 // indirect
k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 // indirect
k8s.io/apiextensions-apiserver v0.30.0 // indirect
k8s.io/code-generator v0.30.0 // indirect
k8s.io/gengo v0.0.0-20240228010128-51d4e06bde70 // indirect
k8s.io/gengo/v2 v2.0.0-20240228010128-51d4e06bde70 // indirect
k8s.io/klog/v2 v2.120.1 // indirect
k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340 // indirect
k8s.io/utils v0.0.0-20230726121419-3b25d923346b // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
)
Loading

0 comments on commit 2b6bd9b

Please sign in to comment.