Skip to content

Commit 61ad772

Browse files
Update dependencies for Kubernetes 1.33 (#108)
* Update dependencies for Kubernetes 1.33 * Update actions/checkout to the latest * Update golangci-lint to the latest
1 parent 6a94f3d commit 61ad772

File tree

9 files changed

+193
-162
lines changed

9 files changed

+193
-162
lines changed

.github/workflows/ci.yaml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
test:
1313
runs-on: ubuntu-latest
1414
steps:
15-
- uses: actions/checkout@v4
15+
- uses: actions/checkout@v5
1616
- uses: actions/setup-go@v5
1717
with:
1818
go-version-file: "go.mod"
@@ -21,22 +21,20 @@ jobs:
2121
docker-build:
2222
runs-on: ubuntu-latest
2323
steps:
24-
- uses: actions/checkout@v4
24+
- uses: actions/checkout@v5
2525
- run: make docker-build
2626

2727
lint-go:
2828
runs-on: ubuntu-latest
2929
steps:
30-
- uses: actions/checkout@v4
30+
- uses: actions/checkout@v5
3131
- uses: actions/setup-go@v5
3232
with:
3333
go-version-file: "go.mod"
34-
- uses: golangci/golangci-lint-action@v6
35-
with:
36-
version: v1.63
34+
- run: make lint
3735

3836
lint-chart:
3937
runs-on: ubuntu-latest
4038
steps:
41-
- uses: actions/checkout@v4
39+
- uses: actions/checkout@v5
4240
- run: make lint-chart

.github/workflows/release.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
IMG: ghcr.io/${{github.repository}}:${{github.ref_name}}
1515
IMG_LATEST: ghcr.io/${{github.repository}}:latest
1616
steps:
17-
- uses: actions/checkout@v4
17+
- uses: actions/checkout@v5
1818

1919
# Publish Container Image
2020
- name: Login to GitHub Container Registry

.github/workflows/tagpr.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
tagpr:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v4
11+
- uses: actions/checkout@v5
1212
- id: tagpr
1313
name: Tagpr
1414
uses: Songmu/tagpr@v1

.golangci.yml

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,20 @@
1-
run:
2-
timeout: 5m
1+
version: "2"
2+
linters:
3+
exclusions:
4+
generated: lax
5+
presets:
6+
- comments
7+
- common-false-positives
8+
- legacy
9+
- std-error-handling
10+
paths:
11+
- third_party$
12+
- builtin$
13+
- examples$
14+
formatters:
15+
exclusions:
16+
generated: lax
17+
paths:
18+
- third_party$
19+
- builtin$
20+
- examples$

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Build the manager binary
2-
FROM --platform=$BUILDPLATFORM golang:1.22 AS builder
2+
FROM --platform=$BUILDPLATFORM golang:1.25 AS builder
33

44
ARG TARGETOS TARGETARCH
55

Makefile

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ IMG ?= ghcr.io/pfnet-research/gcp-workload-identity-federation-webhook:$(TAG)
55
IMG_LATEST ?= ghcr.io/pfnet-research/gcp-workload-identity-federation-webhook:latest
66

77
# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
8-
ENVTEST_K8S_VERSION = 1.31
8+
ENVTEST_K8S_VERSION = 1.33
99

1010
# Get the currently used golang install path (in GOPATH/bin, unless GOBIN is set)
1111
ifeq (,$(shell go env GOBIN))
@@ -58,6 +58,10 @@ fmt: ## Run go fmt against code.
5858
vet: ## Run go vet against code.
5959
go vet ./...
6060

61+
.PHONY: lint
62+
lint: golangci-lint ## Run linter against code.
63+
$(GOLANGCI_LINT) run
64+
6165
.PHONY: test
6266
test: manifests generate fmt vet envtest ## Run tests.
6367
KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) -p path --arch $(shell go env GOARCH))" go test ./... -coverprofile cover.out
@@ -127,14 +131,20 @@ LOCALBIN ?= $(shell pwd)/bin
127131
$(LOCALBIN):
128132
mkdir -p $(LOCALBIN)
129133

134+
.PHONY: clean
135+
clean:
136+
rm -rf $(LOCALBIN)
137+
130138
## Tool Binaries
131139
KUSTOMIZE ?= $(LOCALBIN)/kustomize
132140
CONTROLLER_GEN ?= $(LOCALBIN)/controller-gen
133141
ENVTEST ?= $(LOCALBIN)/setup-envtest
142+
GOLANGCI_LINT ?= $(LOCALBIN)/golangci-lint
134143

135144
## Tool Versions
136-
KUSTOMIZE_VERSION ?= v5.4.2
137-
CONTROLLER_TOOLS_VERSION ?= v0.16.5
145+
KUSTOMIZE_VERSION ?= v5.7.1
146+
CONTROLLER_TOOLS_VERSION ?= v0.18.0
147+
GOLANGCI_LINT_VERSION ?= v2.4.0
138148

139149
KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
140150
.PHONY: kustomize
@@ -151,3 +161,8 @@ $(CONTROLLER_GEN): $(LOCALBIN)
151161
envtest: $(ENVTEST) ## Download envtest-setup locally if necessary.
152162
$(ENVTEST): $(LOCALBIN)
153163
GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-runtime/tools/setup-envtest@latest
164+
165+
.PHONY: golangci-lint
166+
golangci-lint: $(GOLANGCI_LINT) ## Download golangci-lint locally if necessary.
167+
$(GOLANGCI_LINT): $(LOCALBIN)
168+
GOBIN=$(LOCALBIN) go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@$(GOLANGCI_LINT_VERSION)

go.mod

Lines changed: 48 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,75 +1,78 @@
11
module github.com/pfnet-research/gcp-workload-identity-federation-webhook
22

3-
go 1.22.0
3+
go 1.25.0
44

5-
toolchain go1.22.5
5+
// NOTE: Temporarily lock down kube-openapi
6+
// kube-openapi has a breaking change from 20250701 to 20250709.
7+
// https://github.com/kubernetes/kube-openapi/issues/549
8+
replace k8s.io/kube-openapi => k8s.io/kube-openapi v0.0.0-20250701173324-9bd5c66d9911
69

710
require (
811
github.com/MakeNowJust/heredoc v1.0.0
9-
github.com/go-logr/logr v1.4.2
10-
github.com/google/go-cmp v0.6.0
12+
github.com/go-logr/logr v1.4.3
13+
github.com/google/go-cmp v0.7.0
1114
github.com/onsi/ginkgo/v2 v2.22.2
1215
github.com/onsi/gomega v1.36.2
13-
k8s.io/api v0.31.4
14-
k8s.io/apimachinery v0.31.4
15-
k8s.io/client-go v0.31.4
16-
k8s.io/utils v0.0.0-20240711033017-18e509b52bc8
17-
sigs.k8s.io/controller-runtime v0.19.4
16+
k8s.io/api v0.33.4
17+
k8s.io/apimachinery v0.33.4
18+
k8s.io/client-go v0.33.4
19+
k8s.io/utils v0.0.0-20250604170112-4c0f3b243397
20+
sigs.k8s.io/controller-runtime v0.21.0
1821
)
1922

2023
require (
2124
github.com/beorn7/perks v1.0.1 // indirect
25+
github.com/blang/semver/v4 v4.0.0 // indirect
2226
github.com/cespare/xxhash/v2 v2.3.0 // indirect
2327
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
24-
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
25-
github.com/evanphx/json-patch/v5 v5.9.0 // indirect
26-
github.com/fsnotify/fsnotify v1.7.0 // indirect
27-
github.com/fxamacker/cbor/v2 v2.7.0 // indirect
28+
github.com/emicklei/go-restful/v3 v3.13.0 // indirect
29+
github.com/evanphx/json-patch/v5 v5.9.11 // indirect
30+
github.com/fsnotify/fsnotify v1.9.0 // indirect
31+
github.com/fxamacker/cbor/v2 v2.9.0 // indirect
2832
github.com/go-logr/zapr v1.3.0 // indirect
29-
github.com/go-openapi/jsonpointer v0.19.6 // indirect
30-
github.com/go-openapi/jsonreference v0.20.2 // indirect
31-
github.com/go-openapi/swag v0.22.4 // indirect
33+
github.com/go-openapi/jsonpointer v0.21.2 // indirect
34+
github.com/go-openapi/jsonreference v0.21.0 // indirect
35+
github.com/go-openapi/swag v0.23.1 // indirect
3236
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
3337
github.com/gogo/protobuf v1.3.2 // indirect
34-
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
35-
github.com/golang/protobuf v1.5.4 // indirect
36-
github.com/google/gnostic-models v0.6.8 // indirect
37-
github.com/google/gofuzz v1.2.0 // indirect
38+
github.com/google/btree v1.1.3 // indirect
39+
github.com/google/gnostic-models v0.7.0 // indirect
3840
github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad // indirect
3941
github.com/google/uuid v1.6.0 // indirect
40-
github.com/imdario/mergo v0.3.6 // indirect
4142
github.com/josharian/intern v1.0.0 // indirect
4243
github.com/json-iterator/go v1.1.12 // indirect
43-
github.com/mailru/easyjson v0.7.7 // indirect
44+
github.com/mailru/easyjson v0.9.0 // indirect
4445
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
4546
github.com/modern-go/reflect2 v1.0.2 // indirect
4647
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
47-
github.com/pkg/errors v0.9.1 // indirect
48-
github.com/prometheus/client_golang v1.19.1 // indirect
49-
github.com/prometheus/client_model v0.6.1 // indirect
50-
github.com/prometheus/common v0.55.0 // indirect
51-
github.com/prometheus/procfs v0.15.1 // indirect
52-
github.com/spf13/pflag v1.0.5 // indirect
48+
github.com/prometheus/client_golang v1.23.0 // indirect
49+
github.com/prometheus/client_model v0.6.2 // indirect
50+
github.com/prometheus/common v0.65.0 // indirect
51+
github.com/prometheus/procfs v0.17.0 // indirect
52+
github.com/spf13/pflag v1.0.7 // indirect
5353
github.com/x448/float16 v0.8.4 // indirect
5454
go.uber.org/multierr v1.11.0 // indirect
55-
go.uber.org/zap v1.26.0 // indirect
56-
golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect
57-
golang.org/x/net v0.33.0 // indirect
58-
golang.org/x/oauth2 v0.21.0 // indirect
59-
golang.org/x/sys v0.28.0 // indirect
60-
golang.org/x/term v0.27.0 // indirect
61-
golang.org/x/text v0.21.0 // indirect
62-
golang.org/x/time v0.3.0 // indirect
63-
golang.org/x/tools v0.28.0 // indirect
64-
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
65-
google.golang.org/protobuf v1.36.1 // indirect
55+
go.uber.org/zap v1.27.0 // indirect
56+
go.yaml.in/yaml/v2 v2.4.2 // indirect
57+
go.yaml.in/yaml/v3 v3.0.4 // indirect
58+
golang.org/x/net v0.43.0 // indirect
59+
golang.org/x/oauth2 v0.30.0 // indirect
60+
golang.org/x/sync v0.16.0 // indirect
61+
golang.org/x/sys v0.35.0 // indirect
62+
golang.org/x/term v0.34.0 // indirect
63+
golang.org/x/text v0.28.0 // indirect
64+
golang.org/x/time v0.12.0 // indirect
65+
golang.org/x/tools v0.36.0 // indirect
66+
gomodules.xyz/jsonpatch/v2 v2.5.0 // indirect
67+
google.golang.org/protobuf v1.36.7 // indirect
68+
gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect
6669
gopkg.in/inf.v0 v0.9.1 // indirect
67-
gopkg.in/yaml.v2 v2.4.0 // indirect
6870
gopkg.in/yaml.v3 v3.0.1 // indirect
69-
k8s.io/apiextensions-apiserver v0.31.0 // indirect
71+
k8s.io/apiextensions-apiserver v0.33.4 // indirect
7072
k8s.io/klog/v2 v2.130.1 // indirect
71-
k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340 // indirect
72-
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
73-
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
74-
sigs.k8s.io/yaml v1.4.0 // indirect
73+
k8s.io/kube-openapi v0.0.0-20250814151709-d7b6acb124c3 // indirect
74+
sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 // indirect
75+
sigs.k8s.io/randfill v1.0.0 // indirect
76+
sigs.k8s.io/structured-merge-diff/v4 v4.6.0 // indirect
77+
sigs.k8s.io/yaml v1.6.0 // indirect
7578
)

0 commit comments

Comments
 (0)