Skip to content

Commit 2f14f27

Browse files
committed
bump to golang 1.22
* bump in go.mod (base and api) * bump go-toolset in Dockerfile * bump in github jobs ('.github/workflows') * Bump the golangci-lint version in the .pre-commit-config.yaml to v1.63.4 * Bump build_root_image in .ci-operator.yaml to ci-build-root-golang-1.22-sdk-1.31 Jira: OSPRH-12935 Signed-off-by: Martin Schuppert <mschuppert@redhat.com>
1 parent 49734b3 commit 2f14f27

12 files changed

Lines changed: 47 additions & 27 deletions

File tree

.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.22-sdk-1.31

.github/workflows/build-openstack-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: openstack
18-
go_version: 1.21.x
18+
go_version: 1.22.x
1919
operator_sdk_version: 1.31.0
2020
bundle_dockerfile: ./bundle.Dockerfile
2121
secrets:

.github/workflows/docs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
- name: Install Go
2222
uses: actions/setup-go@v3
2323
with:
24-
go-version: 1.21.x
24+
go-version: 1.22.x
2525
- uses: actions/checkout@v4
2626
with:
2727
# this fetches all branches. Needed because we need gh-pages branch for deploy to work

.github/workflows/kustom.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Install Go
1717
uses: actions/setup-go@v3
1818
with:
19-
go-version: 1.21.x
19+
go-version: 1.22.x
2020
- uses: actions/checkout@v4
2121
with:
2222
# this fetches all branches. Needed because we need gh-pages branch for deploy to work

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ repos:
7070
entry: bashate --error . --ignore=E006,E040,E011,E020,E012
7171

7272
- repo: https://github.com/golangci/golangci-lint
73-
rev: v1.59.1
73+
rev: v1.63.4
7474
hooks:
7575
- id: golangci-lint-full
7676
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.22
22
ARG OPERATOR_BASE_IMAGE=registry.access.redhat.com/ubi9/ubi-minimal:latest
33
# Build the manager binary
44
FROM $GOLANG_BUILDER AS builder

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ tidy: ## Run go mod tidy on every mod file in the repo
184184

185185
.PHONY: golangci-lint
186186
golangci-lint:
187-
test -s $(LOCALBIN)/golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.59.1
187+
test -s $(LOCALBIN)/golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.63.4
188188
$(LOCALBIN)/golangci-lint run --fix
189189

190190
MAX_PROCS := 5
@@ -306,8 +306,8 @@ KUSTOMIZE_VERSION ?= v5.5.0 #(dprince: bumped to aquire new features like --load
306306
CONTROLLER_TOOLS_VERSION ?= v0.14.0
307307
CRD_MARKDOWN_VERSION ?= v0.0.3
308308
KUTTL_VERSION ?= 0.17.0
309-
GOTOOLCHAIN_VERSION ?= go1.21.0
310-
OC_VERSION ?= 4.14.0
309+
GOTOOLCHAIN_VERSION ?= go1.22.0
310+
OC_VERSION ?= 4.16.0
311311

312312
KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
313313
.PHONY: kustomize

apis/go.mod

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/openstack-k8s-operators/openstack-operator/apis
22

3-
go 1.21
3+
go 1.22
44

55
require (
66
github.com/cert-manager/cert-manager v1.14.7
@@ -115,3 +115,13 @@ replace github.com/openshift/api => github.com/openshift/api v0.0.0-202408300231
115115

116116
// custom RabbitmqClusterSpecCore for OpenStackControlplane (v2.9.0_patches_tag)
117117
replace github.com/rabbitmq/cluster-operator/v2 => github.com/openstack-k8s-operators/rabbitmq-cluster-operator/v2 v2.6.1-0.20241017142550-a3524acedd49 //allow-merging
118+
119+
replace github.com/openstack-k8s-operators/lib-common/modules/ansible => github.com/stuggi/lib-common/modules/ansible v0.0.0-20250423100326-d1496a001ace
120+
121+
replace github.com/openstack-k8s-operators/lib-common/modules/certmanager => github.com/stuggi/lib-common/modules/certmanager v0.0.0-20250423100326-d1496a001ace
122+
123+
replace github.com/openstack-k8s-operators/lib-common/modules/common => github.com/stuggi/lib-common/modules/common v0.0.0-20250423100326-d1496a001ace
124+
125+
replace github.com/openstack-k8s-operators/lib-common/modules/storage => github.com/stuggi/lib-common/modules/storage v0.0.0-20250423100326-d1496a001ace
126+
127+
replace github.com/openstack-k8s-operators/lib-common/modules/test => github.com/stuggi/lib-common/modules/test v0.0.0-20250423100326-d1496a001ace

apis/go.sum

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,12 +112,8 @@ github.com/openstack-k8s-operators/ironic-operator/api v0.6.1-0.20250411120811-7
112112
github.com/openstack-k8s-operators/ironic-operator/api v0.6.1-0.20250411120811-7144328c4245/go.mod h1:G763C10iPG/LndV3YHVbIR9TAVC9Y1a/hGo2BE4jdhY=
113113
github.com/openstack-k8s-operators/keystone-operator/api v0.6.1-0.20250411095611-8c6f7c175271 h1:bxylJDALqTTCNg5L7aRcp4w9YwSGbEDLDfESh1Nwn14=
114114
github.com/openstack-k8s-operators/keystone-operator/api v0.6.1-0.20250411095611-8c6f7c175271/go.mod h1:kn18hOc8aogrUa0lbxmv52KCYLqSOI3p/aDQePUPIqw=
115-
github.com/openstack-k8s-operators/lib-common/modules/common v0.6.1-0.20250408123225-0d9e9b82c41b h1:T+N6xOT2NP+hVp2K1xl/NV3uheVHu38CcBuW+8uOBYw=
116-
github.com/openstack-k8s-operators/lib-common/modules/common v0.6.1-0.20250408123225-0d9e9b82c41b/go.mod h1:A9Ohw5Q90YOGhcDF4ZHkMr5RArz3phoBu9+ibbYDKG4=
117115
github.com/openstack-k8s-operators/lib-common/modules/openstack v0.6.1-0.20250408123225-0d9e9b82c41b h1:WvlbQ1nXX3MuVKVXdd2o5EK0RDMy5x/VtV845ReUlM4=
118116
github.com/openstack-k8s-operators/lib-common/modules/openstack v0.6.1-0.20250408123225-0d9e9b82c41b/go.mod h1:fesgTbs2j30Fhw2hebXkPgbeAIqG0Yk2oaeOklAInZg=
119-
github.com/openstack-k8s-operators/lib-common/modules/storage v0.6.1-0.20250408123225-0d9e9b82c41b h1:eFKmZDCOLmdrTf3h1ELb/wroxfCHQhNZPdCvEe1RZMU=
120-
github.com/openstack-k8s-operators/lib-common/modules/storage v0.6.1-0.20250408123225-0d9e9b82c41b/go.mod h1:5+v92XC/PRATIiBrhNLEpJ+T4R9JpxBCgRP6QvbfwgE=
121117
github.com/openstack-k8s-operators/manila-operator/api v0.6.1-0.20250412074041-e1b175f03ca6 h1:v80Vmk0hOABmBMFWWKVXb+b3UdiCaYnQMA3VO4DAxL0=
122118
github.com/openstack-k8s-operators/manila-operator/api v0.6.1-0.20250412074041-e1b175f03ca6/go.mod h1:ijxeOiqW1pSp2Q78KWiTfTE1jY46qEah0TiAgs1I/7c=
123119
github.com/openstack-k8s-operators/mariadb-operator/api v0.6.1-0.20250411072738-2702b8a23032 h1:aSJGatuocUI0KHJwVt5LNWxHyTIHKN+9cHzictG8vVw=
@@ -167,6 +163,10 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+
167163
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
168164
github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA=
169165
github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
166+
github.com/stuggi/lib-common/modules/common v0.0.0-20250423100326-d1496a001ace h1:W35jtB8bwYs7FEsxwoZuaSPY8aXqPxlinbOYsVTAwwQ=
167+
github.com/stuggi/lib-common/modules/common v0.0.0-20250423100326-d1496a001ace/go.mod h1:QmGkUfl8iceTifZnCDRPUFgURtRgkSPcidVbJEtlCq4=
168+
github.com/stuggi/lib-common/modules/storage v0.0.0-20250423100326-d1496a001ace h1:KuuYuzo0DYA7EyegyM9MlwWLWfZnQlx/JtirA1jURRA=
169+
github.com/stuggi/lib-common/modules/storage v0.0.0-20250423100326-d1496a001ace/go.mod h1:O3TJ9Dod5XDyRdjwArkDFuSho6mujP/VAxNI+8c91V4=
170170
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
171171
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
172172
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=

go.mod

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/openstack-k8s-operators/openstack-operator
22

3-
go 1.21
3+
go 1.22
44

55
require (
66
github.com/cert-manager/cert-manager v1.14.7
@@ -125,3 +125,13 @@ replace github.com/openshift/api => github.com/openshift/api v0.0.0-202408300231
125125

126126
// custom RabbitmqClusterSpecCore for OpenStackControlplane (v2.9.0_patches_tag)
127127
replace github.com/rabbitmq/cluster-operator/v2 => github.com/openstack-k8s-operators/rabbitmq-cluster-operator/v2 v2.6.1-0.20241017142550-a3524acedd49 //allow-merging
128+
129+
replace github.com/openstack-k8s-operators/lib-common/modules/ansible => github.com/stuggi/lib-common/modules/ansible v0.0.0-20250423100326-d1496a001ace
130+
131+
replace github.com/openstack-k8s-operators/lib-common/modules/certmanager => github.com/stuggi/lib-common/modules/certmanager v0.0.0-20250423100326-d1496a001ace
132+
133+
replace github.com/openstack-k8s-operators/lib-common/modules/common => github.com/stuggi/lib-common/modules/common v0.0.0-20250423100326-d1496a001ace
134+
135+
replace github.com/openstack-k8s-operators/lib-common/modules/storage => github.com/stuggi/lib-common/modules/storage v0.0.0-20250423100326-d1496a001ace
136+
137+
replace github.com/openstack-k8s-operators/lib-common/modules/test => github.com/stuggi/lib-common/modules/test v0.0.0-20250423100326-d1496a001ace

0 commit comments

Comments
 (0)