Skip to content

Commit 087c379

Browse files
authored
move to go 1.17.4 and update dependencies (zalando#1717)
* move to go 1.17.4 and update dependencies * use go install for mockgen and kind
1 parent 07fd4ec commit 087c379

File tree

13 files changed

+506
-167
lines changed

13 files changed

+506
-167
lines changed

Diff for: .github/workflows/run_e2e.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
- uses: actions/checkout@v1
1515
- uses: actions/setup-go@v2
1616
with:
17-
go-version: "^1.16.9"
17+
go-version: "^1.17.4"
1818
- name: Make dependencies
1919
run: make deps mocks
2020
- name: Compile

Diff for: .github/workflows/run_tests.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
- uses: actions/checkout@v2
1515
- uses: actions/setup-go@v2
1616
with:
17-
go-version: "^1.16.9"
17+
go-version: "^1.17.4"
1818
- name: Make dependencies
1919
run: make deps mocks
2020
- name: Compile

Diff for: Makefile

+3-3
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ docker: ${DOCKERDIR}/${DOCKERFILE} docker-context
7373
cd "${DOCKERDIR}" && docker build --rm -t "$(IMAGE):$(TAG)$(CDP_TAG)$(DEBUG_FRESH)$(DEBUG_POSTFIX)" -f "${DOCKERFILE}" .
7474

7575
indocker-race:
76-
docker run --rm -v "${GOPATH}":"${GOPATH}" -e GOPATH="${GOPATH}" -e RACE=1 -w ${PWD} golang:1.8.1 bash -c "make linux"
76+
docker run --rm -v "${GOPATH}":"${GOPATH}" -e GOPATH="${GOPATH}" -e RACE=1 -w ${PWD} golang:1.17.3 bash -c "make linux"
7777

7878
push:
7979
docker push "$(IMAGE):$(TAG)$(CDP_TAG)"
@@ -85,8 +85,8 @@ mocks:
8585
GO111MODULE=on go generate ./...
8686

8787
tools:
88-
GO111MODULE=on go get k8s.io/[email protected].3
89-
GO111MODULE=on go get github.com/golang/mock/[email protected]
88+
GO111MODULE=on go get -d k8s.io/[email protected].4
89+
GO111MODULE=on go install github.com/golang/mock/[email protected]
9090
GO111MODULE=on go mod tidy
9191

9292
fmt:

Diff for: delivery.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ pipeline:
1616
- desc: 'Install go'
1717
cmd: |
1818
cd /tmp
19-
wget -q https://storage.googleapis.com/golang/go1.16.9.linux-amd64.tar.gz -O go.tar.gz
19+
wget -q https://storage.googleapis.com/golang/go1.17.4.linux-amd64.tar.gz -O go.tar.gz
2020
tar -xf go.tar.gz
2121
mv go /usr/local
2222
ln -s /usr/local/go/bin/go /usr/bin/go

Diff for: docker/DebugDockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ COPY build/* /
99
RUN addgroup -g 1000 pgo
1010
RUN adduser -D -u 1000 -G pgo -g 'Postgres Operator' pgo
1111

12-
RUN go get github.com/derekparker/delve/cmd/dlv
12+
RUN go get -d github.com/derekparker/delve/cmd/dlv
1313
RUN cp /root/go/bin/dlv /dlv
1414
RUN chown -R pgo:pgo /dlv
1515

Diff for: docs/developer.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ features and tests.
77

88
Postgres Operator is written in Go. Use the [installation instructions](https://golang.org/doc/install#install)
99
if you don't have Go on your system. You won't be able to compile the operator
10-
with Go older than 1.16. We recommend installing [the latest one](https://golang.org/dl/).
10+
with Go older than 1.17. We recommend installing [the latest one](https://golang.org/dl/).
1111

1212
Go projects expect their source code and all the dependencies to be located
1313
under the [GOPATH](https://github.com/golang/go/wiki/GOPATH). Normally, one
@@ -176,7 +176,7 @@ go get -u github.com/derekparker/delve/cmd/dlv
176176

177177
```
178178
RUN apk --no-cache add go git musl-dev
179-
RUN go get github.com/derekparker/delve/cmd/dlv
179+
RUN go get -d github.com/derekparker/delve/cmd/dlv
180180
```
181181

182182
* Update the `Makefile` to build the project with debugging symbols. For that

Diff for: e2e/Makefile

+3-3
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ push: docker
4545

4646
tools:
4747
# install pinned version of 'kind'
48-
# go get must run outside of a dir with a (module-based) Go project !
49-
# otherwise go get updates project's dependencies and/or behaves differently
50-
cd "/tmp" && GO111MODULE=on go get sigs.k8s.io/[email protected]
48+
# go install must run outside of a dir with a (module-based) Go project !
49+
# otherwise go install updates project's dependencies and/or behaves differently
50+
cd "/tmp" && GO111MODULE=on go install sigs.k8s.io/[email protected]
5151

5252
e2etest: tools copy clean
5353
./run.sh main

Diff for: go.mod

+58-9
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,69 @@
11
module github.com/zalando/postgres-operator
22

3-
go 1.16
3+
go 1.17
44

55
require (
6-
github.com/aws/aws-sdk-go v1.41.16
6+
github.com/aws/aws-sdk-go v1.42.18
77
github.com/golang/mock v1.6.0
8-
github.com/lib/pq v1.10.3
8+
github.com/lib/pq v1.10.4
99
github.com/motomux/pretty v0.0.0-20161209205251-b2aad2c9a95d
1010
github.com/r3labs/diff v1.1.0
1111
github.com/sirupsen/logrus v1.8.1
1212
github.com/stretchr/testify v1.7.0
13-
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519
13+
golang.org/x/crypto v0.0.0-20211202192323-5770296d904e
1414
gopkg.in/yaml.v2 v2.4.0
15-
k8s.io/api v0.22.3
16-
k8s.io/apiextensions-apiserver v0.22.3
17-
k8s.io/apimachinery v0.22.3
18-
k8s.io/client-go v0.22.3
19-
k8s.io/code-generator v0.22.3
15+
k8s.io/api v0.22.4
16+
k8s.io/apiextensions-apiserver v0.22.4
17+
k8s.io/apimachinery v0.22.4
18+
k8s.io/client-go v0.22.4
19+
k8s.io/code-generator v0.22.4
20+
)
21+
22+
require (
23+
github.com/PuerkitoBio/purell v1.1.1 // indirect
24+
github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 // indirect
25+
github.com/davecgh/go-spew v1.1.1 // indirect
26+
github.com/emicklei/go-restful v2.9.5+incompatible // indirect
27+
github.com/evanphx/json-patch v4.11.0+incompatible // indirect
28+
github.com/go-logr/logr v0.4.0 // indirect
29+
github.com/go-openapi/jsonpointer v0.19.5 // indirect
30+
github.com/go-openapi/jsonreference v0.19.5 // indirect
31+
github.com/go-openapi/swag v0.19.14 // indirect
32+
github.com/gogo/protobuf v1.3.2 // indirect
33+
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
34+
github.com/golang/protobuf v1.5.2 // indirect
35+
github.com/google/go-cmp v0.5.5 // indirect
36+
github.com/google/gofuzz v1.1.0 // indirect
37+
github.com/googleapis/gnostic v0.5.5 // indirect
38+
github.com/imdario/mergo v0.3.5 // indirect
39+
github.com/jmespath/go-jmespath v0.4.0 // indirect
40+
github.com/josharian/intern v1.0.0 // indirect
41+
github.com/json-iterator/go v1.1.11 // indirect
42+
github.com/kr/text v0.2.0 // indirect
43+
github.com/mailru/easyjson v0.7.6 // indirect
44+
github.com/moby/spdystream v0.2.0 // indirect
45+
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
46+
github.com/modern-go/reflect2 v1.0.1 // indirect
47+
github.com/pkg/errors v0.9.1 // indirect
48+
github.com/pmezard/go-difflib v1.0.0 // indirect
49+
github.com/spf13/pflag v1.0.5 // indirect
50+
golang.org/x/mod v0.5.1 // indirect
51+
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2 // indirect
52+
golang.org/x/oauth2 v0.0.0-20210402161424-2e8d93401602 // indirect
53+
golang.org/x/sys v0.0.0-20211124211545-fe61309f8881 // indirect
54+
golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d // indirect
55+
golang.org/x/text v0.3.6 // indirect
56+
golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac // indirect
57+
golang.org/x/tools v0.1.7 // indirect
58+
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
59+
google.golang.org/appengine v1.6.7 // indirect
60+
google.golang.org/protobuf v1.26.0 // indirect
61+
gopkg.in/inf.v0 v0.9.1 // indirect
62+
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
63+
k8s.io/gengo v0.0.0-20201214224949-b6c5ce23f027 // indirect
64+
k8s.io/klog/v2 v2.9.0 // indirect
65+
k8s.io/kube-openapi v0.0.0-20211109043538-20434351676c // indirect
66+
k8s.io/utils v0.0.0-20210819203725-bdf08cb9a70a // indirect
67+
sigs.k8s.io/structured-merge-diff/v4 v4.1.2 // indirect
68+
sigs.k8s.io/yaml v1.2.0 // indirect
2069
)

0 commit comments

Comments
 (0)