Skip to content

Commit 9853190

Browse files
authored
Upgrade golang to v1.23 and dependencies to latest; fix compatibility changes with k8s apis (#301)
* Bump golang to v1.23 and dependencies to latest; fix compatibility changes with k8s apis * Add registry manifest
1 parent 717e1cc commit 9853190

22 files changed

+817
-1244
lines changed

.github/workflows/build.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ jobs:
1414
GO111MODULE: on
1515
steps:
1616
- uses: actions/checkout@v3
17-
- name: Set up GO 1.18.x
17+
- name: Set up GO 1.23.x
1818
uses: actions/setup-go@v3
1919
with:
20-
go-version: '1.18'
20+
go-version: '1.23'
2121
check-latest: true
2222

2323
- run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
@@ -32,10 +32,10 @@ jobs:
3232
GO111MODULE: on
3333
steps:
3434
- uses: actions/checkout@v3
35-
- name: Set up GO 1.18.x
35+
- name: Set up GO 1.23.x
3636
uses: actions/setup-go@v3
3737
with:
38-
go-version: '1.18'
38+
go-version: '1.23'
3939
check-latest: true
4040

4141
- run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
@@ -50,10 +50,10 @@ jobs:
5050
GO111MODULE: on
5151
steps:
5252
- uses: actions/checkout@v3
53-
- name: Set up GO 1.18.x
53+
- name: Set up GO 1.23.x
5454
uses: actions/setup-go@v3
5555
with:
56-
go-version: '1.18'
56+
go-version: '1.23'
5757
check-latest: true
5858

5959
- run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
@@ -78,10 +78,10 @@ jobs:
7878
GO111MODULE: on
7979
steps:
8080
- uses: actions/checkout@v3
81-
- name: Set up GO 1.18.x
81+
- name: Set up GO 1.23.x
8282
uses: actions/setup-go@v3
8383
with:
84-
go-version: '1.18'
84+
go-version: '1.23'
8585
check-latest: true
8686

8787
- run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
@@ -96,10 +96,10 @@ jobs:
9696
GO111MODULE: on
9797
steps:
9898
- uses: actions/checkout@v3
99-
- name: Set up GO 1.18.x
99+
- name: Set up GO 1.23.x
100100
uses: actions/setup-go@v3
101101
with:
102-
go-version: '1.18'
102+
go-version: '1.23'
103103
check-latest: true
104104

105105
- run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH

.github/workflows/tag.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ jobs:
1616
uses: actions/checkout@v3
1717
with:
1818
fetch-depth: 0
19-
- name: Set up GO 1.18.x
19+
- name: Set up GO 1.23.x
2020
uses: actions/setup-go@v3
2121
with:
22-
go-version: '1.18'
22+
go-version: '1.23'
2323
check-latest: true
2424

2525
- name: Import GPG key

.goreleaser.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ archives:
3131
format: zip
3232
name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}'
3333
checksum:
34+
extra_files:
35+
- glob: 'terraform-registry-manifest.json'
36+
name_template: '{{ .ProjectName }}_{{ .Version }}_manifest.json'
3437
name_template: '{{ .ProjectName }}_{{ .Version }}_SHA256SUMS'
3538
algorithm: sha256
3639
signs:
@@ -44,4 +47,7 @@ signs:
4447
- "--detach-sign"
4548
- "${artifact}"
4649
release:
50+
extra_files:
51+
- glob: 'terraform-registry-manifest.json'
52+
name_template: '{{ .ProjectName }}_{{ .Version }}_manifest.json'
4753
draft: false

Makefile

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
CURRENT_DIR=$(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
22
TEST?=$$(go list ./... |grep -v 'vendor')
3-
GOFMT_FILES?=$$(find . -name '*.go' |grep -v vendor)
43
PKG_NAME=kubernetes
54
export GO111MODULE=on
65

@@ -41,8 +40,12 @@ vet:
4140
exit 1; \
4241
fi
4342

43+
update-deps:
44+
go get -u ./...
45+
go mod tidy
46+
4447
fmt:
45-
gofmt -w $(GOFMT_FILES)
48+
gofmt -s -w .
4649

4750
fmtcheck:
4851
@sh -c "'$(CURDIR)/scripts/gofmtcheck.sh'"
@@ -51,11 +54,12 @@ errcheck:
5154
@sh -c "'$(CURDIR)/scripts/errcheck.sh'"
5255

5356
ci-build-setup:
54-
sudo rm /usr/local/bin/docker-compose
55-
curl -L https://github.com/docker/compose/releases/download/1.25.4/docker-compose-`uname -s`-`uname -m` > docker-compose
57+
sudo rm -f /usr/local/bin/docker-compose
58+
curl -L https://github.com/docker/compose/releases/download/v2.30.3/docker-compose-`uname -s`-`uname -m` > docker-compose
5659
chmod +x docker-compose
5760
sudo mv docker-compose /usr/local/bin
5861
curl -Lo kubectl https://storage.googleapis.com/kubernetes-release/release/v1.20.7/bin/linux/amd64/kubectl
62+
curl -LO "https://dl.k8s.io/release/v1.31.3/bin/linux/amd64/kubectl"
5963
chmod +x kubectl
6064
sudo mv kubectl /usr/local/bin/
6165
bash scripts/gogetcookie.sh

0 commit comments

Comments
 (0)