Skip to content

Commit

Permalink
Update golang to active supported version
Browse files Browse the repository at this point in the history
Signed-off-by: Henry Wang <henwang@amazon.com>
  • Loading branch information
henry118 committed Mar 8, 2024
1 parent 845a737 commit 4fad2b0
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ name: test
on: ["push", "pull_request"]

env:
GO_VERSION: "1.19"
GO_VERSION: "1.22"
LINUX_ARCHES: "amd64 386 arm arm64 s390x mips64le ppc64le"

jobs:
Expand All @@ -20,10 +20,10 @@ jobs:
- uses: ibiqlik/action-yamllint@v3
with:
format: auto
- uses: golangci/golangci-lint-action@v3
- uses: golangci/golangci-lint-action@v4
with:
args: --verbose
version: v1.51.2
version: v1.54
build:
name: Build all linux architectures
needs: lint
Expand Down Expand Up @@ -55,8 +55,6 @@ jobs:
- uses: actions/checkout@v4

- name: Install test binaries
env:
GO111MODULE: off
run: |
go get github.com/mattn/goveralls
go get github.com/modocache/gover
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/containernetworking/cni

go 1.18
go 1.21

require (
github.com/Masterminds/semver/v3 v3.2.1
Expand Down
2 changes: 1 addition & 1 deletion mk/dependencies/golangci.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
set -e

GOLANGCI_LINT_VERSION="v1.51.2"
GOLANGCI_LINT_VERSION="v1.54"

go install "github.com/golangci/golangci-lint/cmd/golangci-lint@${GOLANGCI_LINT_VERSION}"
3 changes: 2 additions & 1 deletion scripts/release.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/usr/bin/env bash
set -xe

GOLANG="${GOLANG:-golang:1.21-alpine}"
SRC_DIR="${SRC_DIR:-$PWD}"
BUILDFLAGS="-a --ldflags '-extldflags \"-static\"'"

Expand All @@ -14,7 +15,7 @@ rm -Rf ${SRC_DIR}/${RELEASE_DIR}
mkdir -p ${SRC_DIR}/${RELEASE_DIR}
mkdir -p ${OUTPUT_DIR}

docker run -i -v ${SRC_DIR}:/opt/src --rm golang:1.14-alpine \
docker run -i -v ${SRC_DIR}:/opt/src --rm "${GOLANG}" \
/bin/sh -xe -c "\
apk --no-cache add bash tar;
cd /opt/src; umask 0022;
Expand Down

0 comments on commit 4fad2b0

Please sign in to comment.