Skip to content

Commit

Permalink
Upgrade to go1.21.0 (#4450)
Browse files Browse the repository at this point in the history
Also the go compiler version is now always reported with a patch version
so we can remove the whole go_version_full/go_version distinction in the
Makefile.

Fixed up the compiler tarball URL to match what is now present on the
Go downloads page.

Signed-off-by: Andrew Harding <azdagron@gmail.com>
  • Loading branch information
azdagron authored Aug 21, 2023
1 parent 940c1ea commit 4d96a37
Show file tree
Hide file tree
Showing 7 changed files with 75 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pr_build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ on:
pull_request: {}
workflow_dispatch: {}
env:
GO_VERSION: 1.20.5
GO_VERSION: 1.21.0
permissions:
contents: read

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release_build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
tags:
- 'v[0-9].[0-9]+.[0-9]+'
env:
GO_VERSION: 1.20.5
GO_VERSION: 1.21.0
jobs:
cache-deps:
name: cache-deps (linux)
Expand Down
2 changes: 1 addition & 1 deletion .go-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.20.5
1.21.0
11 changes: 5 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -122,17 +122,16 @@ binaries := spire-server spire-agent oidc-discovery-provider

build_dir := $(DIR)/.build/$(os1)-$(arch1)

go_version_full := $(shell cat .go-version)
go_version := $(go_version_full:.0=)
go_version := $(shell cat .go-version)
go_dir := $(build_dir)/go/$(go_version)

ifeq ($(os1),windows)
go_bin_dir = $(go_dir)/go/bin
go_url = https://storage.googleapis.com/golang/go$(go_version).$(os1)-$(arch2).zip
go_url = https://go.dev/dl/go$(go_version).$(os1)-$(arch2).zip
exe=".exe"
else
go_bin_dir = $(go_dir)/bin
go_url = https://storage.googleapis.com/golang/go$(go_version).$(os1)-$(arch2).tar.gz
go_url = https://go.dev/dl/go$(go_version).$(os1)-$(arch2).tar.gz
exe=
endif

Expand Down Expand Up @@ -355,7 +354,7 @@ $1: $3 container-builder
@echo Building docker image $2 $(PLATFORM)
$(E)docker buildx build \
--platform $(PLATFORMS) \
--build-arg goversion=$(go_version_full) \
--build-arg goversion=$(go_version) \
--target $2 \
-o type=oci,dest=$2-image.tar \
-f $3 \
Expand Down Expand Up @@ -386,7 +385,7 @@ define windows_image_rule
$1: $3
@echo Building docker image $2…
$(E)docker build \
--build-arg goversion=$(go_version_full) \
--build-arg goversion=$(go_version) \
--target $2 \
-t $2 -t $2:latest-local \
-f $3 \
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/spiffe/spire

go 1.20
go 1.21

require (
cloud.google.com/go/iam v1.1.1
Expand Down
65 changes: 65 additions & 0 deletions go.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion pkg/agent/plugin/workloadattestor/k8s/k8s_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ func (s *Suite) TestAttestOverSecurePortViaClientAuth() {
s.writeCert(certPath, clientCert)

s.clock.Add(defaultReloadInterval)
s.requireAttestFailure(p, codes.Internal, "tls: bad certificate")
s.requireAttestFailure(p, codes.Internal, "remote error: tls")
}

func (s *Suite) TestAttestOverSecurePortViaAnonymousAuth() {
Expand Down

0 comments on commit 4d96a37

Please sign in to comment.