Skip to content

Commit 627e8ec

Browse files
Merge pull request #267 from red-hat-storage/sync_ds--main
Syncing latest changes from main for ocs-client-operator
2 parents 3bfd841 + 7d92043 commit 627e8ec

File tree

26 files changed

+483
-206
lines changed

26 files changed

+483
-206
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
apiVersion: v1
2+
data:
3+
generateRbdOMapInfo: "true"
24
kind: ConfigMap
35
metadata:
46
name: ocs-client-operator-config

bundle/manifests/ocs-client-operator.clusterserviceversion.yaml

+9-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ metadata:
77
categories: Storage
88
console.openshift.io/plugins: '["odf-client-console"]'
99
containerImage: quay.io/ocs-dev/ocs-client-operator:latest
10-
createdAt: "2024-10-29T07:06:57Z"
10+
createdAt: "2024-11-14T15:13:37Z"
1111
description: OpenShift Data Foundation client operator enables consumption of
1212
storage services from a remote centralized OpenShift Data Foundation provider
1313
cluster.
@@ -21,7 +21,7 @@ metadata:
2121
support: Red Hat
2222
labels:
2323
operatorframework.io/arch.amd64: supported
24-
name: ocs-client-operator.v4.17.0
24+
name: ocs-client-operator.v4.18.0
2525
namespace: placeholder
2626
spec:
2727
apiservicedefinitions: {}
@@ -397,6 +397,12 @@ spec:
397397
verbs:
398398
- get
399399
- list
400+
- apiGroups:
401+
- quota.openshift.io
402+
resources:
403+
- clusterresourcequotas
404+
verbs:
405+
- get
400406
serviceAccountName: ocs-client-operator-status-reporter
401407
deployments:
402408
- label:
@@ -661,4 +667,4 @@ spec:
661667
maturity: alpha
662668
provider:
663669
name: Red Hat
664-
version: 4.17.0
670+
version: 4.18.0

bundle/metadata/dependencies.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@ dependencies:
22
- type: olm.package
33
value:
44
packageName: csi-addons
5-
version: '>=0.9.1'
5+
version: '>=0.10.0'
66
- type: olm.package
77
value:
88
packageName: cephcsi-operator
9-
version: 4.17.0
9+
version: 4.18.0
1010
- type: olm.package
1111
value:
1212
packageName: noobaa-operator
13-
version: ">=5.16.0 <=5.17.0"
13+
version: ">=5.17.0 <=5.18.0"

cmd/main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ import (
3131
// Import all Kubernetes client auth plugins (e.g. Azure, GCP, OIDC, etc.)
3232
// to ensure that exec-entrypoint and run can make use of them.
3333
csiopv1a1 "github.com/ceph/ceph-csi-operator/api/v1alpha1"
34-
snapapi "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
34+
snapapi "github.com/kubernetes-csi/external-snapshotter/client/v8/apis/volumesnapshot/v1"
3535
nbapis "github.com/noobaa/noobaa-operator/v5/pkg/apis"
3636
configv1 "github.com/openshift/api/config/v1"
3737
consolev1 "github.com/openshift/api/console/v1"

config/manager/kustomization.yaml

+3-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@ configMapGenerator:
99
- files:
1010
- controller_manager_config.yaml
1111
name: manager-config
12-
- name: config
12+
- literals:
13+
- generateRbdOMapInfo=true
14+
name: config
1315

1416
apiVersion: kustomize.config.k8s.io/v1beta1
1517
kind: Kustomization

config/metadata/dependencies.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@ dependencies:
22
- type: olm.package
33
value:
44
packageName: csi-addons
5-
version: '>=0.9.1'
5+
version: '>=0.10.0'
66
- type: olm.package
77
value:
88
packageName: cephcsi-operator
9-
version: 4.17.0
9+
version: 4.18.0
1010
- type: olm.package
1111
value:
1212
packageName: noobaa-operator
13-
version: ">=5.16.0 <=5.17.0"
13+
version: ">=5.17.0 <=5.18.0"

config/rbac/status-reporter-clusterrole.yaml

+6
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,9 @@ rules:
2929
verbs:
3030
- get
3131
- list
32+
- apiGroups:
33+
- quota.openshift.io
34+
resources:
35+
- clusterresourcequotas
36+
verbs:
37+
- get

go.mod

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@ exclude (
2020
require (
2121
github.com/ceph/ceph-csi-operator/api v0.0.0-20240812072523-4d50cf3a32a0
2222
github.com/go-logr/logr v1.4.2
23-
github.com/kubernetes-csi/external-snapshotter/client/v6 v6.3.0
23+
github.com/kubernetes-csi/external-snapshotter/client/v8 v8.0.0
2424
github.com/onsi/ginkgo v1.16.5
2525
github.com/onsi/gomega v1.34.1
2626
github.com/openshift/api v0.0.0-20240828125535-01b3675ba7b3
2727
github.com/operator-framework/api v0.27.0
2828
github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.76.0
2929
github.com/ramendr/ramen/api v0.0.0-20241001141243-29d6f22ad237
3030
github.com/red-hat-storage/ocs-client-operator/api v0.0.0-00010101000000-000000000000
31-
github.com/red-hat-storage/ocs-operator/services/provider/api/v4 v4.0.0-20240917115204-741b9d6f263d
31+
github.com/red-hat-storage/ocs-operator/services/provider/api/v4 v4.0.0-20241113175552-201c936738fd
3232
github.com/stretchr/testify v1.9.0
3333
google.golang.org/grpc v1.66.0
3434
k8s.io/api v0.31.0

go.sum

+4-4
Original file line numberDiff line numberDiff line change
@@ -254,8 +254,8 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
254254
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
255255
github.com/kube-object-storage/lib-bucket-provisioner v0.0.0-20221122204822-d1a8c34382f1 h1:dQEHhTfi+bSIOSViQrKY9PqJvZenD6tFz+3lPzux58o=
256256
github.com/kube-object-storage/lib-bucket-provisioner v0.0.0-20221122204822-d1a8c34382f1/go.mod h1:my+EVjOJLeQ9lUR9uVkxRvNNkhO2saSGIgzV8GZT9HY=
257-
github.com/kubernetes-csi/external-snapshotter/client/v6 v6.3.0 h1:qS4r4ljINLWKJ9m9Ge3Q3sGZ/eIoDVDT2RhAdQFHb1k=
258-
github.com/kubernetes-csi/external-snapshotter/client/v6 v6.3.0/go.mod h1:oGXx2XTEzs9ikW2V6IC1dD8trgjRsS/Mvc2JRiC618Y=
257+
github.com/kubernetes-csi/external-snapshotter/client/v8 v8.0.0 h1:mjQG0Vakr2h246kEDR85U8y8ZhPgT3bguTCajRa/jaw=
258+
github.com/kubernetes-csi/external-snapshotter/client/v8 v8.0.0/go.mod h1:E3vdYxHj2C2q6qo8/Da4g7P+IcwqRZyy3gJBzYybV9Y=
259259
github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc=
260260
github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw=
261261
github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
@@ -325,8 +325,8 @@ github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0leargg
325325
github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk=
326326
github.com/ramendr/ramen/api v0.0.0-20241001141243-29d6f22ad237 h1:ig6ePD0yopC5Qi5BRmhsIsKaOkdsGXTSmG3HTYIpquo=
327327
github.com/ramendr/ramen/api v0.0.0-20241001141243-29d6f22ad237/go.mod h1:nO6VM/+PEhcPGyFIQJdhY6ip822cA61PAy/s6IjenAA=
328-
github.com/red-hat-storage/ocs-operator/services/provider/api/v4 v4.0.0-20240917115204-741b9d6f263d h1:RK/zCM6xRwyeJ06u6xSLEwl5Q1g/6EZRQmSgzbqleT0=
329-
github.com/red-hat-storage/ocs-operator/services/provider/api/v4 v4.0.0-20240917115204-741b9d6f263d/go.mod h1:t9GJk69TGXABBF8fFPB+ImpbA9mJyRS86wW6+Qn8xHo=
328+
github.com/red-hat-storage/ocs-operator/services/provider/api/v4 v4.0.0-20241113175552-201c936738fd h1:WIdoP1CE/8yl9tnHFVY7g/h4ZDFk+2Y9Ri0PrHXfx1g=
329+
github.com/red-hat-storage/ocs-operator/services/provider/api/v4 v4.0.0-20241113175552-201c936738fd/go.mod h1:t9GJk69TGXABBF8fFPB+ImpbA9mJyRS86wW6+Qn8xHo=
330330
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
331331
github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8=
332332
github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4=

hack/make-bundle-vars.mk

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# To re-generate a bundle for another specific version without changing the standard setup, you can:
44
# - use the VERSION as arg of the bundle target (e.g make bundle VERSION=0.0.2)
55
# - use environment variables to overwrite this value (e.g export VERSION=0.0.2)
6-
VERSION ?= 4.17.0
6+
VERSION ?= 4.18.0
77

88
# DEFAULT_CHANNEL defines the default channel used in the bundle.
99
# Add a new line here if you would like to change its default config. (E.g DEFAULT_CHANNEL = "stable")
@@ -49,12 +49,12 @@ IMAGE_TAG ?= latest
4949
IMAGE_NAME ?= ocs-client-operator
5050
BUNDLE_IMAGE_NAME ?= $(IMAGE_NAME)-bundle
5151
CSI_ADDONS_BUNDLE_IMAGE_NAME ?= k8s-bundle
52-
CSI_ADDONS_BUNDLE_IMAGE_TAG ?= v0.9.1
52+
CSI_ADDONS_BUNDLE_IMAGE_TAG ?= v0.10.0
5353
CATALOG_IMAGE_NAME ?= $(IMAGE_NAME)-catalog
5454

5555
NOOBAA_BUNDLE_NAME ?= noobaa-operator
5656
NOOBAA_BUNDLE_IMG_NAME ?= $(NOOBAA_BUNDLE_NAME)-bundle
57-
NOOBAA_BUNDLE_VERSION ?= v5.17.0
57+
NOOBAA_BUNDLE_VERSION ?= v5.18.0
5858
NOOBAA_BUNDLE_IMG_TAG ?= master-20240514
5959
NOOBAA_BUNDLE_IMG_NAMESPACE ?= noobaa
6060
NOOBAA_BUNDLE_IMG ?= $(IMAGE_REGISTRY)/$(NOOBAA_BUNDLE_IMG_NAMESPACE)/$(NOOBAA_BUNDLE_IMG_NAME):$(NOOBAA_BUNDLE_IMG_TAG)
@@ -106,7 +106,7 @@ endif
106106

107107
# csi-addons dependencies
108108
CSI_ADDONS_PACKAGE_NAME ?= csi-addons
109-
CSI_ADDONS_PACKAGE_VERSION ?= 0.9.1
109+
CSI_ADDONS_PACKAGE_VERSION ?= 0.10.0
110110

111111
# The following variables are here as a convenience for developers so we don't have
112112
# to retype things, because we're lazy.

internal/controller/operatorconfigmap_controller.go

+7
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ const (
6767
manageNoobaaSubKey = "manageNoobaaSubscription"
6868
subscriptionLabelKey = "managed-by"
6969
subscriptionLabelValue = "webhook.subscription.ocs.openshift.io"
70+
generateRbdOMapInfoKey = "generateRbdOMapInfo"
7071

7172
operatorConfigMapFinalizer = "ocs-client-operator.ocs.openshift.io/storageused"
7273
subPackageIndexName = "index:subscriptionPackage"
@@ -341,6 +342,7 @@ func (c *OperatorConfigMapReconciler) reconcileDelegatedCSI() error {
341342
if err := c.own(rbdDriver); err != nil {
342343
return fmt.Errorf("failed to own csi rbd driver: %v", err)
343344
}
345+
rbdDriver.Spec.GenerateOMapInfo = ptr.To(c.shouldGenerateRBDOmapInfo())
344346
return nil
345347
}); err != nil {
346348
return fmt.Errorf("failed to reconcile rbd driver: %v", err)
@@ -507,6 +509,11 @@ func (c *OperatorConfigMapReconciler) getNoobaaSubManagementConfig() bool {
507509
return val
508510
}
509511

512+
func (c *OperatorConfigMapReconciler) shouldGenerateRBDOmapInfo() bool {
513+
valAsString := strings.ToLower(c.operatorConfigMap.Data[generateRbdOMapInfoKey])
514+
return valAsString == strconv.FormatBool(true)
515+
}
516+
510517
func (c *OperatorConfigMapReconciler) get(obj client.Object, opts ...client.GetOption) error {
511518
return c.Get(c.ctx, client.ObjectKeyFromObject(obj), obj, opts...)
512519
}

0 commit comments

Comments
 (0)