Skip to content

Commit

Permalink
Upgrade to go1.21 & felix 3.27
Browse files Browse the repository at this point in the history
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
  • Loading branch information
sknat committed Dec 19, 2023
1 parent 60e5a55 commit 5ffd8ba
Show file tree
Hide file tree
Showing 5 changed files with 1,314 additions and 296 deletions.
2 changes: 1 addition & 1 deletion .ci/Dockerfile.depend
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ RUN apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y -qq \
apt-utils wget cmake curl git

ENV GOVERSION=1.20.7
ENV GOVERSION=1.21.3
ENV GOROOT="/root/.go"
ENV GOPATH="/root/go"
ENV PATH=$GOROOT/bin:$PATH
Expand Down
3 changes: 1 addition & 2 deletions calico-vpp-agent/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,8 @@ build: felix-api-proxy bin
${DOCKER_RUN} go build -o ./bin/calico-vpp-agent ./cmd
${DOCKER_RUN} go build -o ./bin/debug ./cmd/debug-state

gobgp: GOBGP_DIR:=$(shell ${DOCKER_RUN} go list -f '{{.Dir}}' -m github.com/osrg/gobgp/v3)
gobgp: bin
${DOCKER_RUN} go build -o ./bin/gobgp $(GOBGP_DIR)/cmd/gobgp/
${DOCKER_RUN} go build -o ./bin/gobgp github.com/osrg/gobgp/v3/cmd/gobgp/

image: build gobgp
@echo "Image tag : $(TAG)" > $(VERSION_FILE)
Expand Down
2 changes: 1 addition & 1 deletion calico-vpp-agent/watchers/secret_watcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ func (sw *secretWatcher) GetSecret(name, key string) (string, error) {
}
}

func (sw *secretWatcher) OnAdd(obj interface{}) {
func (sw *secretWatcher) OnAdd(obj interface{}, isInInitialList bool) {
log.Debug("Secret added")
sw.updateSecret(obj.(*v1.Secret))
sw.client.OnSecretUpdate(nil, obj.(*v1.Secret))
Expand Down
204 changes: 103 additions & 101 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,127 +1,133 @@
module github.com/projectcalico/vpp-dataplane/v3

go 1.20
go 1.21

require (
github.com/calico-vpp/vpplink v0.0.0-20230609075304-43385ab1325d
github.com/census-instrumentation/opencensus-proto v0.4.1
github.com/containernetworking/plugins v1.2.0
github.com/containernetworking/plugins v1.3.0
github.com/gogo/protobuf v1.3.2
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/gopacket v1.1.19
github.com/inconshreveable/mousetrap v1.1.0
github.com/k8snetworkplumbingwg/network-attachment-definition-client v1.3.0
github.com/k8snetworkplumbingwg/network-attachment-definition-client v1.4.0
github.com/lunixbochs/struc v0.0.0-20200707160740-784aaebc1d40
github.com/onsi/ginkgo v1.16.5
github.com/onsi/gomega v1.25.0
github.com/onsi/gomega v1.30.0
github.com/orijtech/prometheus-go-metrics-exporter v0.0.6
github.com/osrg/gobgp/v3 v3.10.0
github.com/osrg/gobgp/v3 v3.20.0
github.com/pkg/errors v0.9.1
github.com/projectcalico/api v0.0.0-20230602153125-fb7148692637 // v3.26.0
github.com/projectcalico/calico v0.0.0-20230526220659-8b103f46fbdc // v3.26.0
github.com/sirupsen/logrus v1.9.0
github.com/spf13/cobra v1.7.0
github.com/projectcalico/api v0.0.0-20231218190037-9183ab93f33e // v3.27.0
github.com/projectcalico/calico v0.0.0-20231216011042-6334b9da6086 // v3.27.0
github.com/sirupsen/logrus v1.9.3
github.com/spf13/cobra v1.8.0
github.com/vishvananda/netlink v1.2.1-beta.2.0.20230206183746-70ca0345eede
github.com/vishvananda/netns v0.0.0-20210104183010-2eb08e3e575f
github.com/vishvananda/netns v0.0.4
github.com/yookoala/realpath v1.0.0
go.fd.io/govpp v0.8.0-alpha.0.20230612060736-7e90564236d5
go.fd.io/govpp v0.8.0
go.fd.io/govpp/extras v0.1.1-0.20230330140632-6a7dcb03934f
golang.org/x/net v0.17.0
golang.org/x/sys v0.13.0
google.golang.org/grpc v1.56.3
google.golang.org/protobuf v1.30.0
golang.org/x/net v0.18.0
golang.org/x/sys v0.14.0
google.golang.org/grpc v1.59.0
google.golang.org/protobuf v1.31.0
gopkg.in/tomb.v2 v2.0.0-20161208151619-d5d1b5820637
k8s.io/api v0.26.3
k8s.io/apimachinery v0.26.3
k8s.io/client-go v0.26.3
sigs.k8s.io/controller-runtime v0.12.0
k8s.io/api v0.27.8
k8s.io/apimachinery v0.27.8
k8s.io/client-go v0.27.8
sigs.k8s.io/controller-runtime v0.14.7
)

require (
github.com/bennyscetbun/jsongo v1.1.1 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/coreos/go-semver v0.3.0 // indirect
github.com/coreos/go-semver v0.3.1 // indirect
github.com/coreos/go-systemd/v22 v22.5.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect
github.com/eapache/channels v1.1.0 // indirect
github.com/eapache/queue v1.1.0 // indirect
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
github.com/evanphx/json-patch v4.12.0+incompatible // indirect
github.com/fsnotify/fsnotify v1.6.0 // indirect
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
github.com/evanphx/json-patch v5.7.0+incompatible // indirect
github.com/evanphx/json-patch/v5 v5.7.0 // indirect
github.com/fsnotify/fsnotify v1.7.0 // indirect
github.com/ftrvxmtrx/fd v0.0.0-20150925145434-c6d800382fff // indirect
github.com/go-ini/ini v1.63.2 // indirect
github.com/go-logr/logr v1.2.3 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.1 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/go-playground/locales v0.12.1 // indirect
github.com/go-playground/universal-translator v0.0.0-20170327191703-71201497bace // indirect
github.com/go-ini/ini v1.67.0 // indirect
github.com/go-logr/logr v1.3.0 // indirect
github.com/go-openapi/jsonpointer v0.20.0 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
github.com/go-openapi/swag v0.22.4 // indirect
github.com/go-playground/locales v0.14.1 // indirect
github.com/go-playground/universal-translator v0.18.1 // indirect
github.com/golang-collections/collections v0.0.0-20130729185459-604e922904d3 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/google/gnostic v0.5.7-v3refs // indirect
github.com/google/go-cmp v0.5.9 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/gnostic v0.7.0 // indirect
github.com/google/gnostic-models v0.6.9-0.20230804172637-c7be7c783f49 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/google/uuid v1.4.0 // indirect
github.com/hashicorp/go-version v1.6.0 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/imdario/mergo v0.3.16 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/k-sone/critbitgo v1.4.0 // indirect
github.com/kardianos/osext v0.0.0-20190222173326-2bc1f35cddc0 // indirect
github.com/kelseyhightower/envconfig v0.0.0-20180517194557-dd1402a4d99d // indirect
github.com/leodido/go-urn v0.0.0-20181204092800-a67a23e1c1af // indirect
github.com/kelseyhightower/envconfig v1.4.0 // indirect
github.com/leodido/go-urn v1.2.4 // indirect
github.com/magiconair/properties v1.8.7 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.2 // indirect
github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
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/nxadm/tail v1.4.8 // indirect
github.com/pelletier/go-toml/v2 v2.0.6 // indirect
github.com/nxadm/tail v1.4.11 // indirect
github.com/pelletier/go-toml/v2 v2.1.0 // indirect
github.com/projectcalico/go-json v0.0.0-20161128004156-6219dc7339ba // indirect
github.com/projectcalico/go-yaml-wrapper v0.0.0-20191112210931-090425220c54 // indirect
github.com/prometheus/client_golang v1.14.0 // indirect
github.com/prometheus/client_model v0.3.0 // indirect
github.com/prometheus/common v0.37.0 // indirect
github.com/prometheus/procfs v0.8.0 // indirect
github.com/spf13/afero v1.9.3 // indirect
github.com/spf13/cast v1.5.0 // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/prometheus/client_golang v1.17.0 // indirect
github.com/prometheus/client_model v0.5.0 // indirect
github.com/prometheus/common v0.45.0 // indirect
github.com/prometheus/procfs v0.12.0 // indirect
github.com/sagikazarmark/locafero v0.3.0 // indirect
github.com/sagikazarmark/slog-shim v0.1.0 // indirect
github.com/sourcegraph/conc v0.3.0 // indirect
github.com/spf13/afero v1.10.0 // indirect
github.com/spf13/cast v1.5.1 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/spf13/viper v1.15.0 // indirect
github.com/subosito/gotenv v1.4.2 // indirect
go.etcd.io/etcd/api/v3 v3.5.8 // indirect
go.etcd.io/etcd/client/pkg/v3 v3.5.8 // indirect
go.etcd.io/etcd/client/v3 v3.5.8 // indirect
github.com/spf13/viper v1.17.0 // indirect
github.com/subosito/gotenv v1.6.0 // indirect
go.etcd.io/etcd/api/v3 v3.5.10 // indirect
go.etcd.io/etcd/client/pkg/v3 v3.5.10 // indirect
go.etcd.io/etcd/client/v3 v3.5.10 // indirect
go.opencensus.io v0.24.0 // indirect
go.uber.org/atomic v1.9.0 // indirect
go.uber.org/multierr v1.8.0 // indirect
go.uber.org/zap v1.21.0 // indirect
golang.org/x/crypto v0.14.0 // indirect
golang.org/x/oauth2 v0.7.0 // indirect
golang.org/x/sync v0.1.0 // indirect
golang.org/x/term v0.13.0 // indirect
golang.org/x/text v0.13.0 // indirect
golang.org/x/time v0.1.0 // indirect
golang.zx2c4.com/wireguard/wgctrl v0.0.0-20200324154536-ceff61240acf // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 // indirect
gopkg.in/go-playground/validator.v9 v9.27.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.uber.org/zap v1.26.0 // indirect
golang.org/x/crypto v0.15.0 // indirect
golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa // indirect
golang.org/x/oauth2 v0.14.0 // indirect
golang.org/x/sync v0.5.0 // indirect
golang.org/x/term v0.14.0 // indirect
golang.org/x/text v0.14.0 // indirect
golang.org/x/time v0.4.0 // indirect
golang.zx2c4.com/wireguard/wgctrl v0.0.0-20230429144221-925a1e7659e6 // indirect
google.golang.org/appengine v1.6.8 // indirect
google.golang.org/genproto v0.0.0-20231106174013-bbf56f31fb17 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20231106174013-bbf56f31fb17 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 // indirect
gopkg.in/go-playground/validator.v9 v9.31.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/klog/v2 v2.80.1 // indirect
k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d // indirect
k8s.io/utils v0.0.0-20230313181309-38a27ef9d749 // indirect
k8s.io/klog/v2 v2.110.1 // indirect
k8s.io/kube-openapi v0.0.0-20231113174909-778a5567bc1e // 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/yaml v1.3.0 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
sigs.k8s.io/yaml v1.4.0 // indirect
)

// We match the Calico/VPP version to a given Calico version. In order to upgrade proceed as follows :
Expand All @@ -140,38 +146,34 @@ require (
// - Add comments e.g. `// v3.23.0` to make the commit hash(s) explicit

replace (
github.com/projectcalico/api => github.com/projectcalico/api v0.0.0-20230602153125-fb7148692637 // v3.26.0
k8s.io/api => k8s.io/api v0.26.3
k8s.io/apiextensions-apiserver => k8s.io/apiextensions-apiserver v0.26.3
k8s.io/apimachinery => k8s.io/apimachinery v0.26.3
k8s.io/apiserver => k8s.io/apiserver v0.26.3
k8s.io/cli-runtime => k8s.io/cli-runtime v0.26.3
k8s.io/client-go => k8s.io/client-go v0.26.3
k8s.io/cloud-provider => k8s.io/cloud-provider v0.26.3
k8s.io/cluster-bootstrap => k8s.io/cluster-bootstrap v0.26.3
k8s.io/code-generator => k8s.io/code-generator v0.26.3
k8s.io/component-base => k8s.io/component-base v0.26.3
k8s.io/component-helpers => k8s.io/component-helpers v0.26.3
k8s.io/controller-manager => k8s.io/controller-manager v0.26.3
k8s.io/cri-api => k8s.io/cri-api v0.26.3
k8s.io/csi-translation-lib => k8s.io/csi-translation-lib v0.26.3

k8s.io/dynamic-resource-allocation => k8s.io/dynamic-resource-allocation v0.26.3
k8s.io/kms => k8s.io/kms v0.26.3
k8s.io/kube-aggregator => k8s.io/kube-aggregator v0.26.3
k8s.io/kube-controller-manager => k8s.io/kube-controller-manager v0.26.3
k8s.io/kube-proxy => k8s.io/kube-proxy v0.26.3
k8s.io/kube-scheduler => k8s.io/kube-scheduler v0.26.3
k8s.io/kubectl => k8s.io/kubectl v0.26.3
k8s.io/kubelet => k8s.io/kubelet v0.26.3
k8s.io/api => k8s.io/api v0.27.6
k8s.io/apiextensions-apiserver => k8s.io/apiextensions-apiserver v0.27.6
k8s.io/apimachinery => k8s.io/apimachinery v0.27.6
k8s.io/apiserver => k8s.io/apiserver v0.27.6
k8s.io/cli-runtime => k8s.io/cli-runtime v0.27.6
k8s.io/client-go => k8s.io/client-go v0.27.6
k8s.io/cloud-provider => k8s.io/cloud-provider v0.27.6
k8s.io/cluster-bootstrap => k8s.io/cluster-bootstrap v0.27.6
k8s.io/code-generator => k8s.io/code-generator v0.27.6
k8s.io/component-base => k8s.io/component-base v0.27.6
k8s.io/component-helpers => k8s.io/component-helpers v0.27.6
k8s.io/controller-manager => k8s.io/controller-manager v0.27.6
k8s.io/cri-api => k8s.io/cri-api v0.27.6
k8s.io/csi-translation-lib => k8s.io/csi-translation-lib v0.27.6
k8s.io/kube-aggregator => k8s.io/kube-aggregator v0.27.6
k8s.io/kube-controller-manager => k8s.io/kube-controller-manager v0.27.6
k8s.io/kube-proxy => k8s.io/kube-proxy v0.27.6
k8s.io/kube-scheduler => k8s.io/kube-scheduler v0.27.6
k8s.io/kubectl => k8s.io/kubectl v0.27.6
k8s.io/kubelet => k8s.io/kubelet v0.27.6

// Need replacements for all the k8s subsidiary projects that are pulled in indirectly because
// the kubernets repo pulls them in via a replacement to its own vendored copies, which doesn't work for
// transient imports.
k8s.io/kubernetes => k8s.io/kubernetes v1.26.3
k8s.io/legacy-cloud-providers => k8s.io/legacy-cloud-providers v0.26.3
k8s.io/metrics => k8s.io/metrics v0.26.3
k8s.io/mount-utils => k8s.io/mount-utils v0.26.3
k8s.io/pod-security-admission => k8s.io/pod-security-admission v0.26.3
k8s.io/sample-apiserver => k8s.io/sample-apiserver v0.26.3
k8s.io/kubernetes => k8s.io/kubernetes v1.27.6
k8s.io/legacy-cloud-providers => k8s.io/legacy-cloud-providers v0.27.6
k8s.io/metrics => k8s.io/metrics v0.27.6
k8s.io/mount-utils => k8s.io/mount-utils v0.27.6
k8s.io/pod-security-admission => k8s.io/pod-security-admission v0.27.6
k8s.io/sample-apiserver => k8s.io/sample-apiserver v0.27.6
)
Loading

0 comments on commit 5ffd8ba

Please sign in to comment.