Skip to content

Commit 08cfeaf

Browse files
Merge pull request #499 from stuggi/golang_1.24
[golang] bump to golang 1.24
2 parents f829125 + 3e3d8d6 commit 08cfeaf

22 files changed

Lines changed: 371 additions & 313 deletions

.ci-operator.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
build_root_image:
22
name: tools
33
namespace: openstack-k8s-operators
4-
tag: ci-build-root-golang-1.21-sdk-1.31
4+
tag: ci-build-root-golang-1.24-sdk-1.31

.github/workflows/build-horizon-operator.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
uses: openstack-k8s-operators/openstack-k8s-operators-ci/.github/workflows/reusable-build-operator.yaml@main
1616
with:
1717
operator_name: horizon
18-
go_version: 1.21.x
18+
go_version: 1.24.x
1919
operator_sdk_version: 1.31.0
2020
secrets:
2121
IMAGENAMESPACE: ${{ secrets.IMAGENAMESPACE }}

.github/workflows/force-bump-pr-manual.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,6 @@ jobs:
99
with:
1010
operator_name: horizon
1111
branch_name: ${{ github.ref_name }}
12+
custom_image: quay.io/openstack-k8s-operators/openstack-k8s-operators-ci-build-tools:golang-1.24-sdk-1.31
1213
secrets:
1314
FORCE_BUMP_PULL_REQUEST_PAT: ${{ secrets.FORCE_BUMP_PULL_REQUEST_PAT }}

.github/workflows/force-bump-pr-scheduled.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,6 @@ jobs:
1010
uses: openstack-k8s-operators/openstack-k8s-operators-ci/.github/workflows/force-bump-branches.yaml@main
1111
with:
1212
operator_name: horizon
13+
custom_image: quay.io/openstack-k8s-operators/openstack-k8s-operators-ci-build-tools:golang-1.24-sdk-1.31
1314
secrets:
1415
FORCE_BUMP_PULL_REQUEST_PAT: ${{ secrets.FORCE_BUMP_PULL_REQUEST_PAT }}

.golangci.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,20 @@
1+
version: 2
2+
13
linters:
24
# Enable specific linter
35
# https://golangci-lint.run/usage/linters/#enabled-by-default
46
enable:
57
- errorlint
68
- revive
79
- ginkgolinter
8-
- gofmt
910
- govet
11+
- gosec
12+
- errname
13+
- err113
14+
15+
formatters:
16+
enable:
17+
- gofmt
18+
1019
run:
1120
timeout: 5m

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ repos:
3232
- id: go-mod-tidy
3333

3434
- repo: https://github.com/golangci/golangci-lint
35-
rev: v1.59.1
35+
rev: v2.4.0
3636
hooks:
3737
- id: golangci-lint-full
3838
args: ["-v"]

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG GOLANG_BUILDER=registry.access.redhat.com/ubi9/go-toolset:1.21
1+
ARG GOLANG_BUILDER=registry.access.redhat.com/ubi9/go-toolset:1.24
22
ARG OPERATOR_BASE_IMAGE=registry.access.redhat.com/ubi9/ubi-minimal:latest
33

44
# Build the manager binary

Makefile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@ OPERATOR_SDK_VERSION ?= v1.31.0
5454
DEFAULT_IMG ?= quay.io/openstack-k8s-operators/horizon-operator:latest
5555
IMG ?= $(DEFAULT_IMG)
5656
# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
57-
ENVTEST_K8S_VERSION = 1.29
57+
ENVTEST_K8S_VERSION = 1.31
5858

5959
# Set minimum Go version
60-
GOTOOLCHAIN_VERSION ?= go1.21.0
60+
GOTOOLCHAIN_VERSION ?= go1.24.0
6161

6262
PROCS ?=$(shell expr $(shell nproc --ignore 2) / 4)
6363
# PROC_CMD = --procs ${PROCS}
@@ -202,7 +202,7 @@ GINKGO ?= $(LOCALBIN)/ginkgo
202202

203203
## Tool Versions
204204
KUSTOMIZE_VERSION ?= v3.8.7
205-
CONTROLLER_TOOLS_VERSION ?= v0.14.0
205+
CONTROLLER_TOOLS_VERSION ?= v0.18.0
206206

207207
KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
208208
.PHONY: kustomize $(KUSTOMIZE)
@@ -223,7 +223,7 @@ $(CONTROLLER_GEN): $(LOCALBIN)
223223
.PHONY: envtest
224224
envtest: $(ENVTEST) ## Download envtest-setup locally if necessary.
225225
$(ENVTEST): $(LOCALBIN)
226-
test -s $(LOCALBIN)/setup-envtest || GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-runtime/tools/setup-envtest@c7e1dc9b
226+
test -s $(LOCALBIN)/setup-envtest || GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-runtime/tools/setup-envtest@latest
227227

228228
.PHONY: ginkgo
229229
ginkgo: $(GINKGO) ## Download ginkgo locally if necessary.

api/bases/horizon.openstack.org_horizons.yaml

Lines changed: 87 additions & 25 deletions
Large diffs are not rendered by default.

api/go.mod

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,24 @@
11
module github.com/openstack-k8s-operators/horizon-operator/api
22

3-
go 1.21
3+
go 1.24
44

55
require (
6-
github.com/openstack-k8s-operators/infra-operator/apis v0.6.1-0.20250821143610-c8ef7b9a21ec
7-
github.com/openstack-k8s-operators/lib-common/modules/common v0.6.1-0.20250823121217-7e1cd2e3dd03
8-
github.com/openstack-k8s-operators/lib-common/modules/storage v0.6.1-0.20250823121217-7e1cd2e3dd03
9-
k8s.io/api v0.29.15
10-
k8s.io/apimachinery v0.29.15
11-
sigs.k8s.io/controller-runtime v0.17.6
6+
github.com/openstack-k8s-operators/infra-operator/apis v0.6.1-0.20250922155301-057562fb7182
7+
github.com/openstack-k8s-operators/lib-common/modules/common v0.6.1-0.20250922082314-c83d83092a04
8+
github.com/openstack-k8s-operators/lib-common/modules/storage v0.6.1-0.20250922082314-c83d83092a04
9+
k8s.io/api v0.31.12
10+
k8s.io/apimachinery v0.31.12
11+
sigs.k8s.io/controller-runtime v0.19.7
1212
)
1313

1414
require (
1515
github.com/beorn7/perks v1.0.1 // indirect
16-
github.com/cespare/xxhash/v2 v2.2.0 // indirect
16+
github.com/cespare/xxhash/v2 v2.3.0 // indirect
1717
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
1818
github.com/emicklei/go-restful/v3 v3.12.0 // indirect
1919
github.com/evanphx/json-patch/v5 v5.9.0 // indirect
2020
github.com/fsnotify/fsnotify v1.7.0 // indirect
21+
github.com/fxamacker/cbor/v2 v2.7.0 // indirect
2122
github.com/go-logr/logr v1.4.3 // indirect
2223
github.com/go-openapi/jsonpointer v0.21.0 // indirect
2324
github.com/go-openapi/jsonreference v0.21.0 // indirect
@@ -37,31 +38,30 @@ require (
3738
github.com/modern-go/reflect2 v1.0.2 // indirect
3839
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
3940
github.com/pkg/errors v0.9.1 // indirect
40-
github.com/prometheus/client_golang v1.19.0 // indirect
41-
github.com/prometheus/client_model v0.6.0 // indirect
42-
github.com/prometheus/common v0.51.1 // indirect
43-
github.com/prometheus/procfs v0.13.0 // indirect
41+
github.com/prometheus/client_golang v1.19.1 // indirect
42+
github.com/prometheus/client_model v0.6.1 // indirect
43+
github.com/prometheus/common v0.55.0 // indirect
44+
github.com/prometheus/procfs v0.15.1 // indirect
4445
github.com/spf13/pflag v1.0.5 // indirect
4546
github.com/stretchr/testify v1.10.0 // indirect
47+
github.com/x448/float16 v0.8.4 // indirect
4648
golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect
4749
golang.org/x/net v0.28.0 // indirect
48-
golang.org/x/oauth2 v0.18.0 // indirect
50+
golang.org/x/oauth2 v0.21.0 // indirect
4951
golang.org/x/sys v0.23.0 // indirect
5052
golang.org/x/term v0.23.0 // indirect
5153
golang.org/x/text v0.17.0 // indirect
5254
golang.org/x/time v0.5.0 // indirect
5355
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
54-
google.golang.org/appengine v1.6.8 // indirect
55-
google.golang.org/protobuf v1.34.1 // indirect
56+
google.golang.org/protobuf v1.34.2 // indirect
5657
gopkg.in/inf.v0 v0.9.1 // indirect
5758
gopkg.in/yaml.v2 v2.4.0 // indirect
5859
gopkg.in/yaml.v3 v3.0.1 // indirect
59-
k8s.io/apiextensions-apiserver v0.29.15 // indirect
60-
k8s.io/client-go v0.29.15 // indirect
61-
k8s.io/component-base v0.29.15 // indirect
62-
k8s.io/klog/v2 v2.120.1 // indirect
60+
k8s.io/apiextensions-apiserver v0.31.12 // indirect
61+
k8s.io/client-go v0.31.12 // indirect
62+
k8s.io/klog/v2 v2.130.1 // indirect
6363
k8s.io/kube-openapi v0.0.0-20240322212309-b815d8309940 // indirect
64-
k8s.io/utils v0.0.0-20240711033017-18e509b52bc8 // indirect
64+
k8s.io/utils v0.0.0-20250820121507-0af2bda4dd1d // indirect
6565
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
6666
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
6767
sigs.k8s.io/yaml v1.4.0 // indirect

0 commit comments

Comments
 (0)