Skip to content

Commit

Permalink
template: changes for new kubebuilder
Browse files Browse the repository at this point in the history
template changes for new kubebuilder

Signed-off-by: Madhu Rajanna <[email protected]>
  • Loading branch information
Madhu-1 authored and mergify[bot] committed Sep 3, 2024
1 parent 6cb1ef7 commit a74feed
Show file tree
Hide file tree
Showing 14 changed files with 42 additions and 72 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: csiaddonsnodes.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: encryptionkeyrotationcronjobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: encryptionkeyrotationjobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/csiaddons.openshift.io_networkfences.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: networkfences.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: reclaimspacecronjobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: reclaimspacejobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumegroupreplicationclasses.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumegroupreplicationcontents.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumegroupreplications.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumereplicationclasses.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumereplications.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down
35 changes: 10 additions & 25 deletions config/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,35 +4,11 @@ kind: ClusterRole
metadata:
name: manager-role
rules:
- apiGroups:
- ""
resources:
- persistentvolumeclaims
verbs:
- get
- list
- update
- watch
- apiGroups:
- ""
resources:
- persistentvolumes
verbs:
- get
- list
- watch
- apiGroups:
- coordination.k8s.io
resources:
- leases
verbs:
- get
- list
- watch
- apiGroups:
- ""
resources:
- namespaces
- persistentvolumes
- pods
verbs:
- get
Expand All @@ -46,13 +22,22 @@ rules:
- get
- list
- patch
- update
- watch
- apiGroups:
- ""
resources:
- persistentvolumeclaims/finalizers
verbs:
- update
- apiGroups:
- coordination.k8s.io
resources:
- leases
verbs:
- get
- list
- watch
- apiGroups:
- csiaddons.openshift.io
resources:
Expand Down
22 changes: 11 additions & 11 deletions deploy/controller/crds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: csiaddonsnodes.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down Expand Up @@ -127,7 +127,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: encryptionkeyrotationcronjobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down Expand Up @@ -367,7 +367,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: encryptionkeyrotationjobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down Expand Up @@ -554,7 +554,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: networkfences.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down Expand Up @@ -748,7 +748,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: reclaimspacecronjobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down Expand Up @@ -986,7 +986,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: reclaimspacejobs.csiaddons.openshift.io
spec:
group: csiaddons.openshift.io
Expand Down Expand Up @@ -1181,7 +1181,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumegroupreplicationclasses.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down Expand Up @@ -1257,7 +1257,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumegroupreplicationcontents.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down Expand Up @@ -1430,7 +1430,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumegroupreplications.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down Expand Up @@ -1695,7 +1695,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumereplicationclasses.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down Expand Up @@ -1779,7 +1779,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.16.1
controller-gen.kubebuilder.io/version: v0.16.2
name: volumereplications.replication.storage.openshift.io
spec:
group: replication.storage.openshift.io
Expand Down
35 changes: 10 additions & 25 deletions deploy/controller/rbac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,35 +47,11 @@ kind: ClusterRole
metadata:
name: csi-addons-manager-role
rules:
- apiGroups:
- ""
resources:
- persistentvolumeclaims
verbs:
- get
- list
- update
- watch
- apiGroups:
- ""
resources:
- persistentvolumes
verbs:
- get
- list
- watch
- apiGroups:
- coordination.k8s.io
resources:
- leases
verbs:
- get
- list
- watch
- apiGroups:
- ""
resources:
- namespaces
- persistentvolumes
- pods
verbs:
- get
Expand All @@ -89,13 +65,22 @@ rules:
- get
- list
- patch
- update
- watch
- apiGroups:
- ""
resources:
- persistentvolumeclaims/finalizers
verbs:
- update
- apiGroups:
- coordination.k8s.io
resources:
- leases
verbs:
- get
- list
- watch
- apiGroups:
- csiaddons.openshift.io
resources:
Expand Down

0 comments on commit a74feed

Please sign in to comment.