Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update golang to 1.23 #405

Merged
merged 4 commits into from
Nov 17, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions .github/dependency-review-config.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
warn-only: true

# https://github.com/cncf/foundation/blob/main/allowed-third-party-license-policy.md
allow-licenses:
- 'Apache-2.0'
Expand All @@ -14,7 +16,15 @@ allow-licenses:
allow-dependencies-licenses:
# this action is GPL-3 but it is only used in CI
# https://github.com/actions/dependency-review-action/issues/530#issuecomment-1638291806
- pkg:githubactions/vladopajic/go-test-coverage@bcd064e5ceef1ccec5441519eb054263b6a44787
- pkg:githubactions/vladopajic/go-test-coverage
# this package is MPL-2.0 and has a CNCF exception
# https://github.com/cncf/foundation/blob/9b8c9173c2101c1b4aedad3caf2c0128715133f6/license-exceptions/cncf-exceptions-2022-04-12.json#L43C17-L43C47
# https://github.com/cncf/foundation/blob/main/license-exceptions/cncf-exceptions-2022-04-12.json
- pkg:golang/github.com/go-sql-driver/mysql
# this package is MPL-2.0 and has a CNCF exception
# https://github.com/cncf/foundation/blob/main/license-exceptions/cncf-exceptions-2022-04-12.json
- pkg:golang/github.com/hashicorp/go-version
# this package is MPL-2.0 and has a CNCF exception
# https://github.com/cncf/foundation/blob/main/license-exceptions/cncf-exceptions-2022-04-12.json
- pkg:golang/github.com/hashicorp/golang-lru
# this package is CC0-1.0 and is only used in test asserts
- pkg:golang/github.com/zeebo/assert
6 changes: 3 additions & 3 deletions .github/workflows/goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
matrix:
goversion:
- 1.21
- 1.23
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -31,11 +31,11 @@ jobs:

goreleaser:
needs: test-suite
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
strategy:
matrix:
goversion:
- 1.21
- 1.23
steps:
-
name: Checkout
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lagoon-cli.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
strategy:
matrix:
goversion:
- 1.21
- 1.23
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.21
go-version: 1.23
- name: Build CLI
run: |
go install go.uber.org/mock/[email protected]
Expand Down
4 changes: 2 additions & 2 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ release:
brew install lagoon
```
### Running from released binaries
Alternatively, you may install by downloading one of the pre-compiled binaries (replace `amd64` with `arm64` for ARM-compatible binaries)
Alternatively, you may install by downloading one of the pre-compiled binaries
```
# MacOS
sudo curl -L "https://github.com/{{ .Env.LOCAL_ORG }}/lagoon-cli/releases/download/v{{.Version}}/lagoon-cli-v{{.Version}}-darwin-amd64" -o /usr/local/bin/lagoon && sudo chmod +x /usr/local/bin/lagoon
sudo curl -L "https://github.com/{{ .Env.LOCAL_ORG }}/lagoon-cli/releases/download/v{{.Version}}/lagoon-cli-v{{.Version}}-darwin-arm64" -o /usr/local/bin/lagoon && sudo chmod +x /usr/local/bin/lagoon
# Linux
sudo curl -L "https://github.com/{{ .Env.LOCAL_ORG }}/lagoon-cli/releases/download/v{{.Version}}/lagoon-cli-v{{.Version}}-linux-amd64" -o /usr/local/bin/lagoon && sudo chmod +x /usr/local/bin/lagoon
```
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.21-alpine AS build
FROM golang:1.23-alpine3.20 AS build

WORKDIR /go/src/github.com/uselagoon/lagoon-cli/
COPY . .
Expand All @@ -14,7 +14,7 @@ RUN VERSION=${VERSION:-"$(echo $(git describe --abbrev=0 --tags)+$(git rev-parse
-X github.com/uselagoon/lagoon-cli/cmd.lagoonCLIBuild=$BUILD \
-X github.com/uselagoon/lagoon-cli/cmd.lagoonCLIBuildGoVersion=go$GOLANG_VERSION" -o lagoon .

FROM alpine:3
FROM alpine:3.20

WORKDIR /root/
COPY --from=build /go/src/github.com/uselagoon/lagoon-cli/lagoon /lagoon
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ PKGMODPATH=$(DIR)/vendor
VERSION=$(shell echo $(shell git describe --abbrev=0 --tags)+$(shell git rev-parse --short=8 HEAD))
BUILD=$(shell date +%FT%T%z)

DOCKER_GO_VER=1.21
DOCKER_GO_VER=1.23
GO_VER=$(shell go version)
LDFLAGS=-w -s -X ${PKG}/cmd.lagoonCLIVersion=${VERSION} -X ${PKG}/cmd.lagoonCLIBuild=${BUILD}

Expand Down
Loading
Loading