Skip to content

Commit 687cc26

Browse files
authored
Bump k8s.io/* to v0.37.2 and controller-runtime to v0.25.3 (#407)
- Bump k8s.io/* to v0.37.2 and controller-runtime to v0.25.3 - Other housekeeping tasks and tool updates Signed-off-by: Andreas Fritzler <andreas.fritzler@sap.com>
1 parent e9861d5 commit 687cc26

17 files changed

Lines changed: 96 additions & 124 deletions

File tree

‎.github/workflows/check-codegen.yml‎

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,29 +2,23 @@ name: Check Codegen
22

33
on:
44
pull_request:
5-
paths-ignore:
6-
- 'docs/**'
7-
- '**/*.md'
85

96
jobs:
107
check-codegen:
8+
name: Run code generation checks
119
runs-on: ubuntu-latest
1210
steps:
13-
- uses: actions/checkout@v7
14-
- uses: actions/setup-go@v7
11+
- uses: actions/checkout@v4
12+
- uses: actions/setup-go@v5
1513
with:
1614
go-version-file: 'go.mod'
17-
- name: Run make generate
18-
run: make generate
19-
- name: Run make docs
20-
run: make docs
21-
- name: Run make helm
22-
run: make helm
23-
- name: Compare the expected and actual generated/* directories
15+
- name: Run code gen checks
16+
run: make check-gen
17+
- name: Compare the expected and actual generated files
2418
run: |
25-
if [ "$(git diff | wc -l)" -gt "0" ]; then
26-
echo "Detected uncommitted changes after build. Consider running 'make generate && make docs && make helm'."
19+
if [ -n "$(git status --porcelain=v1)" ]; then
20+
echo "Detected uncommitted changes after build. Consider running 'make generate manifests docs helm fmt'."
2721
echo "See status below:"
28-
git diff
22+
git status --porcelain=v1
2923
exit 1
3024
fi

‎.github/workflows/lint.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@ jobs:
1515
- name: golangci-lint
1616
uses: golangci/golangci-lint-action@v9
1717
with:
18-
version: v2.12
18+
version: v2.15

‎Makefile‎

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,9 @@ manifests: controller-gen ## Generate WebhookConfiguration, ClusterRole and Cust
5454
generate: controller-gen ## Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
5555
$(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./..."
5656

57+
.PHONY: check-gen
58+
check-gen: generate manifests docs helm fmt ## Run all code generation and formatting checks.
59+
5760
.PHONY: fmt
5861
fmt: goimports ## Run goimports against code.
5962
$(GOIMPORTS) -w .
@@ -71,7 +74,10 @@ check-license: addlicense ## Check that every file has a license header present.
7174
find . -name '*.go' -exec $(ADDLICENSE) -check -c 'IronCore authors' {} +
7275

7376
.PHONY: test
74-
test: manifests generate fmt vet setup-envtest ## Run tests.
77+
test: manifests generate fmt vet test-only ## Run tests.
78+
79+
.PHONY: test-only
80+
test-only: setup-envtest ## Run tests without generating manifests or code.
7581
KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) --bin-dir $(LOCALBIN) -p path)" go test $$(go list ./... | grep -v /e2e) -coverprofile cover.out
7682

7783
# TODO(user): To use a different vendor for e2e tests, modify the setup under 'tests/e2e'.
@@ -193,20 +199,19 @@ ADDLICENSE ?= $(LOCALBIN)/addlicense
193199
GOIMPORTS ?= $(LOCALBIN)/goimports
194200
CRD_REF_DOCS ?= $(LOCALBIN)/crd-ref-docs
195201
KUBEBUILDER ?= $(LOCALBIN)/kubebuilder
196-
SETUP_ENVTEST_VERSION ?= v0.17.1 # example pre-0.22
197202

198203
## Tool Versions
199-
KUSTOMIZE_VERSION ?= v5.5.0
200-
CONTROLLER_TOOLS_VERSION ?= v0.17.1
204+
KUSTOMIZE_VERSION ?= v5.8.2
205+
CONTROLLER_TOOLS_VERSION ?= v0.23.0
201206
#ENVTEST_VERSION is the version of controller-runtime release branch to fetch the envtest setup script (i.e. release-0.20)
202207
ENVTEST_VERSION ?= $(shell go list -m -f "{{ .Version }}" sigs.k8s.io/controller-runtime | awk -F'[v.]' '{printf "release-%d.%d", $$2, $$3}')
203208
#ENVTEST_K8S_VERSION is the version of Kubernetes to use for setting up ENVTEST binaries (i.e. 1.31)
204209
ENVTEST_K8S_VERSION ?= $(shell go list -m -f "{{ .Version }}" k8s.io/api | awk -F'[v.]' '{printf "1.%d.%d",$$3, $$2}')
205-
GOLANGCI_LINT_VERSION ?= v2.6
206-
ADDLICENSE_VERSION ?= v1.1.1
207-
GOIMPORTS_VERSION ?= v0.31.0
208-
CRD_REF_DOCS_VERSION ?= v0.2.0
209-
KUBEBUILDER_VERSION ?= v4.5.1
210+
GOLANGCI_LINT_VERSION ?= v2.15
211+
ADDLICENSE_VERSION ?= v1.2.0
212+
GOIMPORTS_VERSION ?= v0.52.0
213+
CRD_REF_DOCS_VERSION ?= v0.3.0
214+
KUBEBUILDER_VERSION ?= v4.16.0
210215

211216
.PHONY: kustomize
212217
kustomize: $(KUSTOMIZE) ## Download kustomize locally if necessary.

‎api/v1alpha1/zz_generated.deepcopy.go‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎cmdutils/suite_test.go‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ var _ = BeforeSuite(func() {
5959
// Note that you must have the required binaries setup under the bin directory to perform
6060
// the tests directly. When we run make test it will be setup and used automatically.
6161
BinaryAssetsDirectory: filepath.Join("..", "bin", "k8s",
62-
fmt.Sprintf("1.35.0-%s-%s", runtime.GOOS, runtime.GOARCH)),
62+
fmt.Sprintf("1.37.0-%s-%s", runtime.GOOS, runtime.GOARCH)),
6363
}
6464

6565
sourceCfg, err := sourceEnv.Start()
@@ -89,7 +89,7 @@ var _ = BeforeSuite(func() {
8989
// Note that you must have the required binaries setup under the bin directory to perform
9090
// the tests directly. When we run make test it will be setup and used automatically.
9191
BinaryAssetsDirectory: filepath.Join("..", "bin", "k8s",
92-
fmt.Sprintf("1.35.0-%s-%s", runtime.GOOS, runtime.GOARCH)),
92+
fmt.Sprintf("1.37.0-%s-%s", runtime.GOOS, runtime.GOARCH)),
9393
}
9494

9595
// cfg is defined in this file globally.

‎config/crd/bases/boot.ironcore.dev_httpbootconfigs.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
33
kind: CustomResourceDefinition
44
metadata:
55
annotations:
6-
controller-gen.kubebuilder.io/version: v0.17.1
6+
controller-gen.kubebuilder.io/version: v0.23.0
77
name: httpbootconfigs.boot.ironcore.dev
88
spec:
99
group: boot.ironcore.dev

‎config/crd/bases/boot.ironcore.dev_ipxebootconfigs.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
33
kind: CustomResourceDefinition
44
metadata:
55
annotations:
6-
controller-gen.kubebuilder.io/version: v0.17.1
6+
controller-gen.kubebuilder.io/version: v0.23.0
77
name: ipxebootconfigs.boot.ironcore.dev
88
spec:
99
group: boot.ironcore.dev

‎dist/chart/templates/certmanager/certificate.yaml‎

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -9,30 +9,6 @@ metadata:
99
namespace: {{ .Release.Namespace }}
1010
spec:
1111
selfSigned: {}
12-
{{- if .Values.webhook.enable }}
13-
---
14-
# Certificate for the webhook
15-
apiVersion: cert-manager.io/v1
16-
kind: Certificate
17-
metadata:
18-
annotations:
19-
{{- if .Values.crd.keep }}
20-
"helm.sh/resource-policy": keep
21-
{{- end }}
22-
name: serving-cert
23-
namespace: {{ .Release.Namespace }}
24-
labels:
25-
{{- include "chart.labels" . | nindent 4 }}
26-
spec:
27-
dnsNames:
28-
- boot-operator.{{ .Release.Namespace }}.svc
29-
- boot-operator.{{ .Release.Namespace }}.svc.cluster.local
30-
- boot-operator-webhook-service.{{ .Release.Namespace }}.svc
31-
issuerRef:
32-
kind: Issuer
33-
name: selfsigned-issuer
34-
secretName: webhook-server-cert
35-
{{- end }}
3612
{{- if .Values.metrics.enable }}
3713
---
3814
# Certificate for the metrics

‎dist/chart/templates/crd/boot.ironcore.dev_httpbootconfigs.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ metadata:
99
{{- if .Values.crd.keep }}
1010
"helm.sh/resource-policy": keep
1111
{{- end }}
12-
controller-gen.kubebuilder.io/version: v0.17.1
12+
controller-gen.kubebuilder.io/version: v0.23.0
1313
name: httpbootconfigs.boot.ironcore.dev
1414
spec:
1515
group: boot.ironcore.dev

‎dist/chart/templates/crd/boot.ironcore.dev_ipxebootconfigs.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ metadata:
99
{{- if .Values.crd.keep }}
1010
"helm.sh/resource-policy": keep
1111
{{- end }}
12-
controller-gen.kubebuilder.io/version: v0.17.1
12+
controller-gen.kubebuilder.io/version: v0.23.0
1313
name: ipxebootconfigs.boot.ironcore.dev
1414
spec:
1515
group: boot.ironcore.dev

0 commit comments

Comments
 (0)