Skip to content

Commit

Permalink
Update to Go 1.20 (#2148)
Browse files Browse the repository at this point in the history
Update Go to ensure security updates are available. Also update
golangci-lint to support Go 1.20
(golangci/golangci-lint#3586).

Fixes #2141
  • Loading branch information
wjam authored and olgibbons committed Mar 16, 2023
1 parent ed5d76c commit 8a84973
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 20 deletions.
18 changes: 9 additions & 9 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
build:
parallelism: 1
environment:
GOVER: 1.19.3
GOVER: 1.20.2
IPFS_VERSION: v0.12.2
GOPROXY: https://proxy.golang.org
GOOS: << parameters.target_os >>
Expand Down Expand Up @@ -235,7 +235,7 @@ jobs:
build_canary:
parallelism: 1
environment:
GOVER: 1.19.3
GOVER: 1.20.2
GOPROXY: https://proxy.golang.org
TARGET_COMMIT: << pipeline.git.revision >>
working_directory: ~/repo
Expand Down Expand Up @@ -276,7 +276,7 @@ jobs:
coverage:
executor: linux-amd64
environment:
GOVER: 1.19.3
GOVER: 1.20.2
GOPROXY: https://proxy.golang.org
steps:
- checkout
Expand All @@ -298,8 +298,8 @@ jobs:
lint:
parallelism: 1
environment:
GOVER: 1.19.3
GOLANGCILINT: v1.49.0
GOVER: 1.20.2
GOLANGCILINT: v1.51.2
GOPROXY: https://proxy.golang.org
working_directory: ~/repo
executor: linux-amd64
Expand Down Expand Up @@ -459,9 +459,9 @@ jobs:
build_swagger:
executor: linux-amd64
environment:
GOVER: 1.19.3
GOVER: 1.20.2
GOPROXY: https://proxy.golang.org
GOLANGCILINT: v1.49.0
GOLANGCILINT: v1.51.2
TARGET_COMMIT: << pipeline.git.revision >>
working_directory: ~/repo
steps:
Expand Down Expand Up @@ -542,9 +542,9 @@ jobs:
build_jsonschema_job:
executor: linux-amd64
environment:
GOVER: 1.19.3
GOVER: 1.20.2
GOPROXY: https://proxy.golang.org
GOLANGCILINT: v1.49.0
GOLANGCILINT: v1.51.2
TARGET_COMMIT: << pipeline.git.revision >>
working_directory: ~/repo
steps:
Expand Down
2 changes: 1 addition & 1 deletion .trunk/trunk.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: 0.1
runtimes:
enabled:
- go@1.19.3
- go@1.20.2
- [email protected]
- [email protected]
actions:
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.dashboard
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.19 as build
FROM golang:1.20 as build
ENV GO111MODULE=on
WORKDIR /app
COPY ./go.mod .
Expand Down
2 changes: 1 addition & 1 deletion docker/bacalhau-image/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# syntax=docker/dockerfile:1.4
FROM cgr.dev/chainguard/go:1.19 as build
FROM cgr.dev/chainguard/go:1.20 as build
WORKDIR /work
COPY Makefile .
COPY go.mod .
Expand Down
2 changes: 1 addition & 1 deletion docs/running_locally.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ This is useful to kick the tires and/or developing on the codebase. It's also t

* x86_64 or ARM64 architecture
* Ubuntu 20.0+ has most often been used for development and testing
* Go >= 1.19
* Go >= 1.20
* [Docker Engine](https://docs.docker.com/get-docker/)
* (Optional) A build of the [latest Bacalhau release](https://github.com/bacalhau-project/bacalhau/releases/)

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/bacalhau-project/bacalhau

go 1.19
go 1.20

require (
github.com/BTBurke/k8sresource v1.2.0
Expand Down
2 changes: 1 addition & 1 deletion go.work
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
go 1.19
go 1.20

use (
.
Expand Down
2 changes: 1 addition & 1 deletion ops/aws/canary/lambda/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/bacalhau-project/bacalhau/ops/aws/canary

go 1.19
go 1.20

require (
github.com/aws/aws-lambda-go v1.34.1
Expand Down
4 changes: 2 additions & 2 deletions ops/aws/canary/lib/pipeline-stack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ export class PipelineStack extends cdk.Stack {
install: {
commands: [
'rm -rf `goenv root`',
'curl --silent --show-error --location --fail https://go.dev/dl/go1.19.6.linux-amd64.tar.gz | tar --extract --gzip --file=- --directory=/usr/local',
'curl --silent --show-error --location --fail https://go.dev/dl/go1.20.2.linux-amd64.tar.gz | tar --extract --gzip --file=- --directory=/usr/local',
'ln -s /usr/local/go/bin/go /usr/local/bin/go',
],
},
Expand Down Expand Up @@ -206,7 +206,7 @@ export class PipelineStack extends cdk.Stack {
install: {
commands: [
'rm -rf `goenv root`',
'curl --silent --show-error --location --fail https://go.dev/dl/go1.19.6.linux-amd64.tar.gz | tar --extract --gzip --file=- --directory=/usr/local',
'curl --silent --show-error --location --fail https://go.dev/dl/go1.20.2.linux-amd64.tar.gz | tar --extract --gzip --file=- --directory=/usr/local',
'ln -s /usr/local/go/bin/go /usr/local/bin/go',
'go install gotest.tools/[email protected]',
],
Expand Down
2 changes: 1 addition & 1 deletion ops/terraform/remote_files/scripts/install-node.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ source /terraform_node/variables
function install-go() {
echo "Installing Go..."
rm -fr /usr/local/go /usr/local/bin/go
curl --silent --show-error --location --fail https://go.dev/dl/go1.19.6.linux-amd64.tar.gz | sudo tar --extract --gzip --file=- --directory=/usr/local
curl --silent --show-error --location --fail https://go.dev/dl/go1.20.2.linux-amd64.tar.gz | sudo tar --extract --gzip --file=- --directory=/usr/local
sudo ln -s /usr/local/go/bin/go /usr/local/bin/go
go version
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/requester/publicapi/endpoints_cancel.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"github.com/rs/zerolog/log"
)

type cancelRequest = SignedRequest[model.JobCancelPayload]
type cancelRequest = SignedRequest[model.JobCancelPayload] //nolint:unused // Swagger wants this

type cancelResponse struct {
State *model.JobState `json:"state"`
Expand Down

0 comments on commit 8a84973

Please sign in to comment.