Skip to content

Commit ccdf388

Browse files
authored
[release-ocm-2.14] ACM-27436: Upgrade Hive to fe9c66be8e113d4268ab744ca708860d0b4cc6e1 (#793)
* ACM-27435: Upgrade API go.mod versions In preparation to upgrade hive in the base repo's go.mod * ACM-27436: Upgrade Hive version Upgrade Hive API version to fe9c66be8e113d4268ab744ca708860d0b4cc6e1 Prevents mismatch in hive version deployed in the hub cluster. * ACM-27436: Upgrade assisted-service API and model to 33a19884b7a7 Prevents deprecated webhook error during code-gen * ACM-27436: Upgrade controller-gen version to 0.19.0 * ACM-27436: Upgrade golangci-lint to v2.6.2 * ACM-27436: Fix linter errors after golanci-lint upgrade * ACM-27436: Update dockerfiles Use the go 1.24 image as a builder and update the ARG to match the MCE version. * ACM-27436: Name controllers to prevent validation error New validation requires controllers to have unique names, otherwise the application will go into crashloopbackoff. Explicitly name controllers since starting multiple controllers without names will auto-name them all the same thing, causing this error. * ACM-27436: Update .ci-operator.yaml file Ensures that the golang version for the CI build jobs match the target version in the repo. * ACM-27436: Generate manifests after upgrade
1 parent 53e575d commit ccdf388

File tree

4,042 files changed

+449271
-157739
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

4,042 files changed

+449271
-157739
lines changed

.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: release
33
namespace: openshift
4-
tag: golang-1.20
4+
tag: rhel-9-release-golang-1.24-openshift-4.21

.golangci.yml

Lines changed: 48 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,77 +1,63 @@
1-
# This file contains all available configuration options
2-
# with their default values.
3-
4-
# options for analysis running
5-
run:
6-
# default concurrency is a available CPU number
7-
concurrency: 4
8-
9-
# timeout for analysis, e.g. 30s, 5m, default is 1m
1+
version: 2
2+
run:
3+
go: "1.24"
104
timeout: 10m
5+
allow-parallel-runners: true
6+
concurrency: 4
117

12-
# exit code when at least one issue was found, default is 1
13-
issues-exit-code: 1
14-
15-
# include test files or not, default is true
16-
tests: true
8+
linters:
9+
default: none
10+
enable:
11+
- errcheck
12+
- govet
13+
- gocyclo
14+
- gosec
15+
- unconvert
16+
- ineffassign
17+
- misspell
18+
- unused
19+
settings:
20+
govet:
21+
enable:
22+
- shadow
23+
settings:
24+
printf:
25+
funcs:
26+
- Infof
27+
- Warnf
28+
- Errorf
29+
- Fatalf
1730

1831
# which dirs to skip: issues from them won't be reported;
1932
# can use regexp here: generated.*, regexp is applied on full path;
2033
# default value is empty list, but default dirs are skipped independently
2134
# from this option's value (see skip-dirs-use-default).
22-
skip-dirs:
23-
- build
24-
- client
25-
- docs
26-
- models
27-
- restapi
28-
- api
29-
30-
# output configuration options
31-
output:
32-
# colored-line-number|line-number|json|tab|checkstyle|code-climate, default is "colored-line-number"
33-
format: colored-line-number
34-
35-
# print lines of code with issue, default is true
36-
print-issued-lines: true
37-
38-
# print linter name in the end of issue text, default is true
39-
print-linter-name: true
40-
41-
# make issues output unique by line, default is true
42-
uniq-by-line: true
35+
exclusions:
36+
paths:
37+
- build
38+
- client
39+
- docs
40+
- models
41+
- restapi
42+
- api
4343

4444
issues:
45-
# List of regexps of issue texts to exclude, empty list by default.
46-
# But independently from this option we use default exclude patterns,
47-
# it can be disabled by `exclude-use-default: false`. To list all
48-
# excluded by default patterns execute `golangci-lint run --help`
49-
exclude:
50-
- G107
51-
- G402 # support object store DisableSSL
52-
- G108
45+
uniq-by-line: true
5346

54-
linters:
47+
formatters:
5548
enable:
56-
- megacheck
57-
- govet
58-
- gocyclo
5949
- gofmt
60-
- gosec
61-
- megacheck
62-
- unconvert
6350
- gci
6451
- goimports
65-
- exportloopref
52+
settings:
53+
gofmt:
54+
simplify: false
6655

67-
linters-settings:
68-
govet:
69-
check-shadowing: true
70-
71-
settings:
72-
printf:
73-
funcs:
74-
- Infof
75-
- Warnf
76-
- Errorf
77-
- Fatalf
56+
# output configuration options
57+
output:
58+
formats:
59+
text:
60+
path: stdout
61+
print-linter-name: true
62+
print-issued-lines: true
63+
colors: true

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 registry.access.redhat.com/ubi9/go-toolset:9.6-1755755147 as builder
2+
FROM registry.access.redhat.com/ubi9/go-toolset:1.24 AS builder
33

44
USER 0
55

Dockerfile.rhtap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Build the manager binary
2-
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_1.23 as builder
2+
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_1.24 as builder
33

44
WORKDIR /workspace
55
COPY . .
@@ -8,7 +8,7 @@ RUN CGO_ENABLED=1 go build -a -o manager main.go
88

99
FROM registry.redhat.io/rhel9-2-els/rhel:9.2
1010

11-
ARG version=2.11
11+
ARG version=2.9
1212

1313
LABEL \
1414
name="multicluster-engine/cluster-api-provider-agent-rhel9" \

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/confi
147147

148148
CONTROLLER_GEN = $(shell pwd)/bin/controller-gen
149149
controller-gen: ## Download controller-gen locally if necessary.
150-
$(call go-get-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/controller-gen@v0.14.0)
150+
$(call go-get-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/controller-gen@v0.19.0)
151151

152152
KUSTOMIZE = $(shell pwd)/bin/kustomize
153153
kustomize: ## Download kustomize locally if necessary.
@@ -163,7 +163,7 @@ mockgen: ## Download mockgen locally if necessary.
163163

164164
GOLINT = $(shell pwd)/bin/golangci-lint
165165
golint: ## Download golangci-lint locally if necessary.
166-
$(call go-get-tool,$(GOLINT),github.com/golangci/golangci-lint/cmd/golangci-lint@v1.54.0)
166+
$(call go-get-tool,$(GOLINT),github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.6.2)
167167

168168
# go-get-tool will 'go get' any package $2 and install it to $1.
169169
PROJECT_DIR := $(shell dirname $(abspath $(lastword $(MAKEFILE_LIST))))

api/go.mod

Lines changed: 29 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,47 @@
11
module github.com/openshift/cluster-api-provider-agent/api
22

3-
go 1.21
3+
go 1.24.0
4+
5+
toolchain go1.24.2
46

57
require (
68
github.com/openshift/api v0.0.0-20240830023148-b7d0481c9094
7-
k8s.io/apimachinery v0.29.9
8-
k8s.io/client-go v0.29.9
9-
sigs.k8s.io/cluster-api v1.7.6
10-
sigs.k8s.io/controller-runtime v0.17.6
9+
k8s.io/apimachinery v0.34.2
10+
k8s.io/client-go v0.34.2
11+
sigs.k8s.io/cluster-api v1.10.0
12+
sigs.k8s.io/controller-runtime v0.22.4
1113
)
1214

1315
require (
14-
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
15-
github.com/go-logr/logr v1.4.1 // indirect
16-
github.com/go-openapi/jsonpointer v0.19.6 // indirect
16+
github.com/emicklei/go-restful/v3 v3.12.2 // indirect
17+
github.com/fxamacker/cbor/v2 v2.9.0 // indirect
18+
github.com/go-logr/logr v1.4.2 // indirect
19+
github.com/go-openapi/jsonpointer v0.21.0 // indirect
1720
github.com/go-openapi/jsonreference v0.20.2 // indirect
18-
github.com/go-openapi/swag v0.22.3 // indirect
21+
github.com/go-openapi/swag v0.23.0 // indirect
1922
github.com/gogo/protobuf v1.3.2 // indirect
20-
github.com/golang/protobuf v1.5.4 // indirect
21-
github.com/google/gnostic-models v0.6.8 // indirect
22-
github.com/google/gofuzz v1.2.0 // indirect
23+
github.com/google/gnostic-models v0.7.0 // indirect
2324
github.com/josharian/intern v1.0.0 // indirect
2425
github.com/json-iterator/go v1.1.12 // indirect
2526
github.com/mailru/easyjson v0.7.7 // indirect
2627
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
27-
github.com/modern-go/reflect2 v1.0.2 // indirect
28+
github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee // indirect
2829
github.com/pkg/errors v0.9.1 // indirect
29-
golang.org/x/net v0.23.0 // indirect
30-
golang.org/x/text v0.14.0 // indirect
31-
google.golang.org/protobuf v1.33.0 // indirect
30+
github.com/x448/float16 v0.8.4 // indirect
31+
go.yaml.in/yaml/v2 v2.4.2 // indirect
32+
go.yaml.in/yaml/v3 v3.0.4 // indirect
33+
golang.org/x/net v0.38.0 // indirect
34+
golang.org/x/text v0.23.0 // indirect
35+
google.golang.org/protobuf v1.36.5 // indirect
3236
gopkg.in/inf.v0 v0.9.1 // indirect
33-
gopkg.in/yaml.v2 v2.4.0 // indirect
3437
gopkg.in/yaml.v3 v3.0.1 // indirect
35-
k8s.io/api v0.29.9 // indirect
36-
k8s.io/apiextensions-apiserver v0.29.3 // indirect
37-
k8s.io/klog/v2 v2.110.1 // indirect
38-
k8s.io/kube-openapi v0.0.0-20231010175941-2dd684a91f00 // indirect
39-
k8s.io/utils v0.0.0-20231127182322-b307cd553661 // indirect
40-
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
41-
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
42-
sigs.k8s.io/yaml v1.4.0 // indirect
38+
k8s.io/api v0.34.2 // indirect
39+
k8s.io/apiextensions-apiserver v0.34.1 // indirect
40+
k8s.io/klog/v2 v2.130.1 // indirect
41+
k8s.io/kube-openapi v0.0.0-20250710124328-f3f2b991d03b // indirect
42+
k8s.io/utils v0.0.0-20250604170112-4c0f3b243397 // indirect
43+
sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8 // indirect
44+
sigs.k8s.io/randfill v1.0.0 // indirect
45+
sigs.k8s.io/structured-merge-diff/v6 v6.3.0 // indirect
46+
sigs.k8s.io/yaml v1.6.0 // indirect
4347
)

0 commit comments

Comments
 (0)