Skip to content

Commit 78fee99

Browse files
author
healthy-pod
committed
*: upgrade to go 1.20.8
* [ ] Adjust the Pebble tests to run in new version. * [ ] Adjust version in Docker image ([source](./builder/Dockerfile)). * [ ] Adjust version in the TeamCity agent image ([setup script](./packer/teamcity-agent.sh)) * [ ] Rebuild and push the Docker image (following [Basic Process](#basic-process)) * [ ] Update `build/teamcity/internal/release/build-and-publish-patched-go/impl.sh` with the new version and adjust SHA256 sums as necessary. * [ ] Adjust `GO_VERSION` and `GO_FIPS_COMMIT` for the FIPS Go toolchain ([source](./teamcity/internal/release/build-and-publish-patched-go/impl-fips.sh)). * [ ] Run the `Internal / Cockroach / Build / Toolchains / Publish Patched Go for Mac` build configuration in TeamCity with your latest version of the script above. Note the job depends on another job `Build and Publish Patched Go`. That job prints out the SHA256 of all tarballs, which you will need to copy-paste into `WORKSPACE` (see below). `Publish Patched Go for Mac` is an extra step that publishes the *signed* `go` binaries for macOS. That job also prints out the SHA256 of the Mac tarballs in particular. * [ ] Adjust `--@io_bazel_rules_go//go/toolchain:sdk_version` in [.bazelrc](../.bazelrc). * [ ] Bump the version in `WORKSPACE` under `go_download_sdk`. You may need to bump [rules_go](https://github.com/bazelbuild/rules_go/releases). Also edit the filenames listed in `sdks` and update all the hashes to match what you built in the step above. * [ ] Bump the version in `WORKSPACE` under `go_download_sdk` for the FIPS version of Go (`go_sdk_fips`). * [ ] Run `./dev generate bazel` to refresh `distdir_files.bzl`, then `bazel fetch @distdir//:archives` to ensure you've updated all hashes to the correct value. * [ ] Bump the version in `builder.sh` accordingly ([source](./builder.sh#L6)). * [ ] Bump the version in `go-version-check.sh` ([source](./go-version-check.sh)), unless bumping to a new patch release. * [ ] Bump the go version in `go.mod`. * [ ] Bump the default installed version of Go in `bootstrap-debian.sh` ([source](./bootstrap/bootstrap-debian.sh)). * [ ] Replace other mentions of the older version of go (grep for `golang:<old_version>` and `go<old_version>`). * [ ] Update the `builder.dockerImage` parameter in the TeamCity [`Cockroach`](https://teamcity.cockroachdb.com/admin/editProject.html?projectId=Cockroach&tab=projectParams) and [`Internal`](https://teamcity.cockroachdb.com/admin/editProject.html?projectId=Internal&tab=projectParams) projects. * [ ] Ask the Developer Infrastructure team to deploy new TeamCity agent images according to [packer/README.md](./packer/README.md) Release note (build change): upgrade to go 1.20.8 Epic: none
1 parent c0f0059 commit 78fee99

File tree

46 files changed

+428
-980
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+428
-980
lines changed

.bazelrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ build:crosslinuxfips '--workspace_status_command=./build/bazelutil/stamp.sh x86_
7979
build:crosslinuxfips --config=crosslinuxfipsbase
8080
build:crosslinuxfipsbase --platforms=//build/toolchains:cross_linux
8181
build:crosslinuxfipsbase --config=cross
82-
build:crosslinuxfipsbase --@io_bazel_rules_go//go/toolchain:sdk_version=1.19.10fips
82+
build:crosslinuxfipsbase --@io_bazel_rules_go//go/toolchain:sdk_version=1.20.7fips
8383
build:crosswindows '--workspace_status_command=./build/bazelutil/stamp.sh x86_64-w64-mingw32'
8484
build:crosswindows --config=crosswindowsbase
8585
build:crosswindowsbase --platforms=//build/toolchains:cross_windows

BUILD.bazel

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ exports_files([
5757
# gazelle:resolve go github.com/cockroachdb/cockroach/pkg/util/json_test //pkg/util/json:json_test
5858
# gazelle:resolve go google.golang.org/genproto/googleapis/pubsub/v1 @org_golang_google_genproto//googleapis/pubsub/v1:pubsub
5959
# gazelle:resolve go google.golang.org/genproto/googleapis/cloud/kms/v1 @org_golang_google_genproto//googleapis/cloud/kms/v1:kms
60+
# gazelle:resolve go google.golang.org/genproto/googleapis/devtools/build/v1 @org_golang_google_genproto//googleapis/devtools/build/v1:build
6061

6162
# See pkg/kv/kvpb/gen/BUILD.bazel for more details.
6263
#

DEPS.bzl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2399,10 +2399,10 @@ def go_deps():
23992399
name = "com_github_docker_docker",
24002400
build_file_proto_mode = "disable_global",
24012401
importpath = "github.com/docker/docker",
2402-
sha256 = "b96610497d8d7b41eff039cd4b4ba595eedb3944b653b813f087364805e3db76",
2403-
strip_prefix = "github.com/moby/moby@v20.10.6+incompatible",
2402+
sha256 = "92fd2184ec4e265dae066c73fc9c7d40254eaeb804f659e7a4cc27ebd3689fcc",
2403+
strip_prefix = "github.com/moby/moby@v24.0.6+incompatible",
24042404
urls = [
2405-
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/moby/com_github_moby_moby-v20.10.6+incompatible.zip",
2405+
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/moby/com_github_moby_moby-v24.0.6+incompatible.zip",
24062406
],
24072407
)
24082408
go_repository(

WORKSPACE

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
88
# Load go bazel tools. This gives us access to the go bazel SDK/toolchains.
99
http_archive(
1010
name = "io_bazel_rules_go",
11-
sha256 = "7ab77b5bd3ac04a65860b0e26f2855c977d463d8e9b5ce2458e516b110eb5eeb",
12-
strip_prefix = "cockroachdb-rules_go-f1ab269",
11+
sha256 = "824f524fed040e3844025a4274ad03523c38aabe1017c52f72e6d721311f07e3",
12+
strip_prefix = "cockroachdb-rules_go-310eb8a",
1313
urls = [
14-
# cockroachdb/rules_go as of f1ab26925b5da24119d38115a657f27a90288db5
15-
# (upstream release-0.40 plus a few patches).
16-
"https://storage.googleapis.com/public-bazel-artifacts/bazel/cockroachdb-rules_go-v0.27.0-341-gf1ab269.tar.gz",
14+
# cockroachdb/rules_go as of 310eb8ab3c7d53c21c8a5805d1ea77e39cf8552b
15+
# (upstream release-0.41 plus a few patches).
16+
"https://storage.googleapis.com/public-bazel-artifacts/bazel/cockroachdb-rules_go-v0.27.0-352-g310eb8a.tar.gz",
1717
]
1818
)
1919

@@ -129,22 +129,22 @@ http_archive(
129129
"-p1",
130130
],
131131
patches = [
132-
"@io_bazel_rules_go//third_party:go_googleapis-deletebuild.patch",
133-
"@io_bazel_rules_go//third_party:go_googleapis-directives.patch",
134-
"@io_bazel_rules_go//third_party:go_googleapis-gazelle.patch",
135132
"@com_github_cockroachdb_cockroach//build/patches:go_googleapis.patch",
136133
],
137134
sha256 = "ba694861340e792fd31cb77274eacaf6e4ca8bda97707898f41d8bebfd8a4984",
138135
strip_prefix = "googleapis-83c3605afb5a39952bf0a0809875d41cf2a558ca",
139136
# master, as of 2022-12-05
140-
# NB: You may have to update this when bumping rules_go. Bumping to the same
141-
# version in rules_go (go/private/repositories.bzl) is probably what you
142-
# want to do.
143137
urls = [
144138
"https://storage.googleapis.com/public-bazel-artifacts/bazel/googleapis-83c3605afb5a39952bf0a0809875d41cf2a558ca.zip",
145139
],
146140
)
147141

142+
load("@go_googleapis//:repository_rules.bzl", "switched_rules_by_language")
143+
144+
switched_rules_by_language(
145+
name = "com_google_googleapis_imports",
146+
)
147+
148148
# com_github_golang_mock handled in DEPS.bzl.
149149

150150
# Load the go dependencies and invoke them.
@@ -162,15 +162,15 @@ load(
162162
go_download_sdk(
163163
name = "go_sdk",
164164
sdks = {
165-
"darwin_amd64": ("go1.19.10.darwin-amd64.tar.gz", "48361d76271f9a725942bdc17012ae9fef72359f7b0aa303deb1098e05ef818c"),
166-
"darwin_arm64": ("go1.19.10.darwin-arm64.tar.gz", "7cc8ab7e8e1225b57f44ec8fb26bce70ddea8e076dfdf118ed63fef0c9ff19fb"),
167-
"freebsd_amd64": ("go1.19.10.freebsd-amd64.tar.gz", "0d22265662eaa9b8136223f8ab68f5c06c58c6a6311748fb810e830ebd17cbe2"),
168-
"linux_amd64": ("go1.19.10.linux-amd64.tar.gz", "dfc8a696686d00065ba374209a3a7858926641e0fb55741dd89c357446d69a1e"),
169-
"linux_arm64": ("go1.19.10.linux-arm64.tar.gz", "e36d6ebfce3f244e245a2969f83d26c8dff2bf8b72207822d9d66829cd93d067"),
170-
"windows_amd64": ("go1.19.10.windows-amd64.tar.gz", "dab9df83e0768ff96eddd85a4def88db05ce5a8a0c439abcecd066888906c516"),
165+
"darwin_amd64": ("go1.20.8.darwin-amd64.tar.gz", "35b0ccd50619bb9fd7ad9418ab937fd9304b219b3b6ecbb89baf34b001ef618d"),
166+
"darwin_arm64": ("go1.20.8.darwin-arm64.tar.gz", "265b2994e56ef0b2fc3b33cae4cb8bad12c4cbfd9ab24e3a58af14fe857f9476"),
167+
"freebsd_amd64": ("go1.20.8.freebsd-amd64.tar.gz", "ea64e0eb4eb0af7ad59d26b9fb6d3facf32393ad6a29d29c34ba7903523443e6"),
168+
"linux_amd64": ("go1.20.8.linux-amd64.tar.gz", "1c4e5509ea7a9619b010aece658af0e4b3be35ba7eeb4e2ba2350b4f56b1209a"),
169+
"linux_arm64": ("go1.20.8.linux-arm64.tar.gz", "e96cb9d4040e938be85be382aed6b9560ee4a372623861040e5b7935ff838bd9"),
170+
"windows_amd64": ("go1.20.8.windows-amd64.tar.gz", "00bf5902a559d2b297a042f87241c2ba4c1139d6bfe02af6e95d4bd6a349f06a"),
171171
},
172-
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/{}"],
173-
version = "1.19.10",
172+
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/{}"],
173+
version = "1.20.8",
174174
)
175175

176176
# To point to a local SDK path, use the following instead. We'll call the
@@ -610,8 +610,8 @@ distdir_repositories()
610610
go_download_sdk(
611611
name = "go_sdk_fips",
612612
sdks = {
613-
"linux_amd64": ("go1.19.10fips.linux-amd64.tar.gz", "c9348fc964fb2893471a6ba91feead205a6f83cd427bc3847949382417005496"),
613+
"linux_amd64": ("go1.20.7fips.linux-amd64.tar.gz", "9cfd219231beb3cf3c9f0258db0edd9af10dadeaa5d563a9f6029e517e44472d"),
614614
},
615-
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/{}"],
616-
version = "1.19.10fips",
615+
urls = ["https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/{}"],
616+
version = "1.20.7fips",
617617
)

build/bazelutil/distdir_files.bzl

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -786,7 +786,7 @@ DISTDIR_FILES = {
786786
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mmatczuk/go_generics/com_github_mmatczuk_go_generics-v0.0.0-20181212143635-0aaa050f9bab.zip": "18c1e95c93f1f82be0184bc13bf49eb4350c7a4ff524b1bf440b3eb9ff14acc9",
787787
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mmcloughlin/geohash/com_github_mmcloughlin_geohash-v0.9.0.zip": "7162856858d9bb3c411d4b42ad19dfff579341ddf0580122e3f1ac3be05c7441",
788788
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/locker/com_github_moby_locker-v1.0.1.zip": "f07361346d12a24e168db7fb2f21281883bee6060f1aedf7507bccf20c4a793f",
789-
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/moby/com_github_moby_moby-v20.10.6+incompatible.zip": "b96610497d8d7b41eff039cd4b4ba595eedb3944b653b813f087364805e3db76",
789+
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/moby/com_github_moby_moby-v24.0.6+incompatible.zip": "92fd2184ec4e265dae066c73fc9c7d40254eaeb804f659e7a4cc27ebd3689fcc",
790790
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/spdystream/com_github_moby_spdystream-v0.2.0.zip": "9db6d001a80f4c3cb332bb8a1bb9260908e1ffa9a20491e9bc05358263eed278",
791791
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/sys/mountinfo/com_github_moby_sys_mountinfo-v0.5.0.zip": "8dfcdd129483164002cae296d0d4e58b139b6576b25e06c325963d902079018c",
792792
"https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/sys/signal/com_github_moby_sys_signal-v0.6.0.zip": "9e4076b073a7536bc05fdfc2432ece1c5d7147a538c19a98b35937a177f8d9e5",
@@ -1166,7 +1166,7 @@ DISTDIR_FILES = {
11661166
"https://storage.googleapis.com/public-bazel-artifacts/bazel/bmatcuk-doublestar-v4.0.1-0-gf7a8118.tar.gz": "d11c3b3a45574f89d6a6b2f50e53feea50df60407b35f36193bf5815d32c79d1",
11671167
"https://storage.googleapis.com/public-bazel-artifacts/bazel/cockroachdb-protobuf-3f5d91f.tar.gz": "6d4e7fe1cbd958dee69ce9becbf8892d567f082b6782d3973a118d0aa00807a8",
11681168
"https://storage.googleapis.com/public-bazel-artifacts/bazel/cockroachdb-rules_foreign_cc-6f7f1b1.tar.gz": "272ac2cde4efd316c8d7c0140dee411c89da104466701ac179286ef5a89c7b58",
1169-
"https://storage.googleapis.com/public-bazel-artifacts/bazel/cockroachdb-rules_go-v0.27.0-341-gf1ab269.tar.gz": "7ab77b5bd3ac04a65860b0e26f2855c977d463d8e9b5ce2458e516b110eb5eeb",
1169+
"https://storage.googleapis.com/public-bazel-artifacts/bazel/cockroachdb-rules_go-v0.27.0-352-g310eb8a.tar.gz": "824f524fed040e3844025a4274ad03523c38aabe1017c52f72e6d721311f07e3",
11701170
"https://storage.googleapis.com/public-bazel-artifacts/bazel/google-starlark-go-e043a3d.tar.gz": "a35c6468e0e0921833a63290161ff903295eaaf5915200bbce272cbc8dfd1c1c",
11711171
"https://storage.googleapis.com/public-bazel-artifacts/bazel/googleapis-83c3605afb5a39952bf0a0809875d41cf2a558ca.zip": "ba694861340e792fd31cb77274eacaf6e4ca8bda97707898f41d8bebfd8a4984",
11721172
"https://storage.googleapis.com/public-bazel-artifacts/bazel/platforms-0.0.4.tar.gz": "079945598e4b6cc075846f7fd6a9d0857c33a7afc0de868c2ccb96405225135d",
@@ -1192,13 +1192,13 @@ DISTDIR_FILES = {
11921192
"https://storage.googleapis.com/public-bazel-artifacts/c-deps/20230718-202534/libproj_foreign.macos.20230718-202534.tar.gz": "96771a33542beb72067afcafaeb790134014e56798fa4cbe291894c4ebf8b68d",
11931193
"https://storage.googleapis.com/public-bazel-artifacts/c-deps/20230718-202534/libproj_foreign.macosarm.20230718-202534.tar.gz": "b2c60ffe1f50c6e81ba906f773b95d3a6699538d57e71749579552f4211a1e3e",
11941194
"https://storage.googleapis.com/public-bazel-artifacts/c-deps/20230718-202534/libproj_foreign.windows.20230718-202534.tar.gz": "16de1e76ee8de4bd144dc57bfde05385d086943ca1b64cc246055c8b0cd71c65",
1195-
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.darwin-amd64.tar.gz": "48361d76271f9a725942bdc17012ae9fef72359f7b0aa303deb1098e05ef818c",
1196-
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.darwin-arm64.tar.gz": "7cc8ab7e8e1225b57f44ec8fb26bce70ddea8e076dfdf118ed63fef0c9ff19fb",
1197-
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.freebsd-amd64.tar.gz": "0d22265662eaa9b8136223f8ab68f5c06c58c6a6311748fb810e830ebd17cbe2",
1198-
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.linux-amd64.tar.gz": "dfc8a696686d00065ba374209a3a7858926641e0fb55741dd89c357446d69a1e",
1199-
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.linux-arm64.tar.gz": "e36d6ebfce3f244e245a2969f83d26c8dff2bf8b72207822d9d66829cd93d067",
1200-
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10.windows-amd64.tar.gz": "dab9df83e0768ff96eddd85a4def88db05ce5a8a0c439abcecd066888906c516",
1201-
"https://storage.googleapis.com/public-bazel-artifacts/go/20230614-165357/go1.19.10fips.linux-amd64.tar.gz": "c9348fc964fb2893471a6ba91feead205a6f83cd427bc3847949382417005496",
1195+
"https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/go1.20.7fips.linux-amd64.tar.gz": "9cfd219231beb3cf3c9f0258db0edd9af10dadeaa5d563a9f6029e517e44472d",
1196+
"https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/go1.20.8.darwin-amd64.tar.gz": "35b0ccd50619bb9fd7ad9418ab937fd9304b219b3b6ecbb89baf34b001ef618d",
1197+
"https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/go1.20.8.darwin-arm64.tar.gz": "265b2994e56ef0b2fc3b33cae4cb8bad12c4cbfd9ab24e3a58af14fe857f9476",
1198+
"https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/go1.20.8.freebsd-amd64.tar.gz": "ea64e0eb4eb0af7ad59d26b9fb6d3facf32393ad6a29d29c34ba7903523443e6",
1199+
"https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/go1.20.8.linux-amd64.tar.gz": "1c4e5509ea7a9619b010aece658af0e4b3be35ba7eeb4e2ba2350b4f56b1209a",
1200+
"https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/go1.20.8.linux-arm64.tar.gz": "e96cb9d4040e938be85be382aed6b9560ee4a372623861040e5b7935ff838bd9",
1201+
"https://storage.googleapis.com/public-bazel-artifacts/go/20230906-184959/go1.20.8.windows-amd64.tar.gz": "00bf5902a559d2b297a042f87241c2ba4c1139d6bfe02af6e95d4bd6a349f06a",
12021202
"https://storage.googleapis.com/public-bazel-artifacts/gomod/github.com/bazelbuild/buildtools/v6.1.2-0-gb182fc4/bazelbuild-buildtools-v6.1.2-0-gb182fc4.tar.gz": "d71a889e3bc50cc8b9d42c859e15a74f7c8d10b6786f8dd82f08f2bf24e5bdc6",
12031203
"https://storage.googleapis.com/public-bazel-artifacts/java/railroad/rr-1.63-java8.zip": "d2791cd7a44ea5be862f33f5a9b3d40aaad9858455828ebade7007ad7113fb41",
12041204
"https://storage.googleapis.com/public-bazel-artifacts/js/rules_jest-v0.18.4.tar.gz": "d3bb833f74b8ad054e6bff5e41606ff10a62880cc99e4d480f4bdfa70add1ba7",

build/bazelutil/nogo_config.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1964,6 +1964,9 @@
19641964
"only_files": {
19651965
"cockroach/pkg/.*$": "first-party code",
19661966
"cockroach/bazel-out/.*/bin/pkg/.*$": "first-party code"
1967+
},
1968+
"exclude_files": {
1969+
"pkg/util/goschedstats/runtime_go.*.go$": "patch code"
19671970
}
19681971
},
19691972
"unreachable": {

build/bootstrap/bootstrap-debian.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,9 @@ sudo tar -C /usr --strip-components=1 -zxf /tmp/cmake.tgz && rm /tmp/cmake.tgz
4343

4444
# Install Go.
4545
trap 'rm -f /tmp/go.tgz' EXIT
46-
curl -fsSL https://dl.google.com/go/go1.19.10.linux-amd64.tar.gz > /tmp/go.tgz
46+
curl -fsSL https://dl.google.com/go/go1.20.7.linux-amd64.tar.gz > /tmp/go.tgz
4747
sha256sum -c - <<EOF
48-
8b045a483d3895c6edba2e90a9189262876190dbbd21756870cdd63821810677 /tmp/go.tgz
48+
f0a87f1bcae91c4b69f8dc2bc6d7e6bfcd7524fceec130af525058c0c17b1b44 /tmp/go.tgz
4949
EOF
5050
sudo tar -C /usr/local -zxf /tmp/go.tgz && rm /tmp/go.tgz
5151

build/builder.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
set -euo pipefail
44

55
image=cockroachdb/builder
6-
version=20230815-142459
6+
version=20230830-211921
77

88
function init() {
99
docker build --tag="${image}" "$(dirname "${0}")/builder"

build/builder/Dockerfile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,10 @@ RUN curl -fsSL https://github.com/Kitware/CMake/releases/download/v3.20.3/cmake-
114114
# NB: care needs to be taken when updating this version because earlier
115115
# releases of Go will no longer be run in CI once it is changed. Consider
116116
# bumping the minimum allowed version of Go in /build/go-version-check.sh.
117-
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends golang \
118-
&& curl -fsSL https://storage.googleapis.com/golang/go1.19.10.src.tar.gz -o golang.tar.gz \
119-
&& echo '13755bcce529747d5f2930dee034730c86d02bd3e521ab3e2bbede548d3b953f golang.tar.gz' | sha256sum -c - \
117+
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y software-properties-common && add-apt-repository ppa:longsleep/golang-backports \
118+
&& apt-get install -y --no-install-recommends golang-go \
119+
&& curl -fsSL https://storage.googleapis.com/golang/go1.20.7.src.tar.gz -o golang.tar.gz \
120+
&& echo '2c5ee9c9ec1e733b0dbbc2bdfed3f62306e51d8172bf38f4f4e542b27520f597 golang.tar.gz' | sha256sum -c - \
120121
&& tar -C /usr/local -xzf golang.tar.gz \
121122
&& rm golang.tar.gz \
122123
&& cd /usr/local/go/src \

build/go-version-check.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# To bump the required version of Go, edit the appropriate variables:
77

88
required_version_major=1
9-
minimum_version_minor=19
9+
minimum_version_minor=20
1010

1111
go=${1-go}
1212

build/packer/teamcity-agent.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,9 +77,9 @@ tar --strip-components=1 -C /usr -xzf /tmp/cmake.tar.gz
7777
rm -f /tmp/cmake.tar.gz
7878

7979
if [[ $ARCH = x86_64 ]]; then
80-
curl -fsSL https://dl.google.com/go/go1.19.10.linux-amd64.tar.gz > /tmp/go.tgz
80+
curl -fsSL https://dl.google.com/go/go1.20.7.linux-amd64.tar.gz > /tmp/go.tgz
8181
sha256sum -c - <<EOF
82-
8b045a483d3895c6edba2e90a9189262876190dbbd21756870cdd63821810677 /tmp/go.tgz
82+
f0a87f1bcae91c4b69f8dc2bc6d7e6bfcd7524fceec130af525058c0c17b1b44 /tmp/go.tgz
8383
EOF
8484
tar -C /usr/local -zxf /tmp/go.tgz && rm /tmp/go.tgz
8585
# Explicitly symlink the pinned version to /usr/bin.

build/patches/go_googleapis.patch

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,34 @@
11
diff -urN a/google/cloud/kms/v1/BUILD.bazel b/google/cloud/kms/v1/BUILD.bazel
22
--- a/google/cloud/kms/v1/BUILD.bazel 1970-01-01 00:00:00.000000000 +0000
33
+++ b/google/cloud/kms/v1/BUILD.bazel 2000-01-01 00:00:00.000000000 -0000
4-
@@ -23,5 +23,11 @@
4+
@@ -128,8 +128,11 @@
55
importpath = "google.golang.org/genproto/googleapis/cloud/kms/v1",
6-
proto = ":kms_proto",
7-
visibility = ["//visibility:public"],
8-
- deps = ["//google/api:annotations_go_proto"],
9-
+ deps = [
6+
protos = [":kms_proto"],
7+
deps = [
8+
- "//google/api:annotations_go_proto",
9+
- "//google/iam/v1:iam_go_proto",
1010
+ "@com_github_golang_protobuf//ptypes/duration:go_default_library",
1111
+ "@com_github_golang_protobuf//ptypes/timestamp:go_default_library",
1212
+ "@com_github_golang_protobuf//ptypes/wrappers:go_default_library",
1313
+ "@org_golang_google_genproto//googleapis/api/annotations:go_default_library",
1414
+ "@org_golang_google_genproto//protobuf/field_mask:go_default_library",
15-
+ ],
15+
],
1616
)
17+
1718
diff -urN a/google/devtools/build/v1/BUILD.bazel a/google/devtools/build/v1/BUILD.bazel
1819
--- a/google/devtools/build/v1/BUILD.bazel 1970-01-01 00:00:00.000000000 +0000
1920
+++ b/google/devtools/build/v1/BUILD.bazel 2000-01-01 00:00:00.000000000 -0000
20-
@@ -25,5 +25,13 @@
21+
@@ -129,7 +129,13 @@
2122
importpath = "google.golang.org/genproto/googleapis/devtools/build/v1",
22-
proto = ":build_proto",
23-
visibility = ["//visibility:public"],
24-
- deps = ["//google/api:annotations_go_proto"],
25-
+ deps = [
23+
protos = [":build_proto"],
24+
deps = [
25+
- "//google/api:annotations_go_proto",
2626
+ "@com_github_golang_protobuf//ptypes/any:go_default_library",
2727
+ "@com_github_golang_protobuf//ptypes/duration:go_default_library",
2828
+ "@com_github_golang_protobuf//ptypes/empty:go_default_library",
2929
+ "@com_github_golang_protobuf//ptypes/timestamp:go_default_library",
3030
+ "@com_github_golang_protobuf//ptypes/wrappers:go_default_library",
3131
+ "@org_golang_google_genproto//googleapis/api/annotations:go_default_library",
3232
+ "@org_golang_google_genproto//protobuf/field_mask:go_default_library",
33-
+ ],
33+
],
3434
)

0 commit comments

Comments
 (0)