Skip to content

Commit

Permalink
k8s: allow operator to create servicemonitors
Browse files Browse the repository at this point in the history
(cherry picked from commit b60bbd3)
  • Loading branch information
alejandroEsc authored and vbotbuildovich committed Aug 30, 2023
1 parent 7c0af7d commit 5e7e2e7
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/go/k8s/config/rbac/bases/operator/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,18 @@ rules:
- get
- patch
- update
- apiGroups:
- monitoring.coreos.com
resources:
- servicemonitors
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- policy
resources:
Expand Down
1 change: 1 addition & 0 deletions src/go/k8s/controllers/redpanda/redpanda_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ type RedpandaReconciler struct {
// +kubebuilder:rbac:groups=apps,namespace=default,resources=deployments,verbs=get;create;update;patch;delete
// +kubebuilder:rbac:groups=cert-manager.io,namespace=default,resources=certificates,verbs=get;create;update;patch;delete
// +kubebuilder:rbac:groups=cert-manager.io,namespace=default,resources=issuers,verbs=get;create;update;patch;delete
// +kubebuilder:rbac:groups="monitoring.coreos.com",namespace=default,resources=servicemonitors,verbs=get;list;watch;create;update;patch;delete

// redpanda resources
// +kubebuilder:rbac:groups=cluster.redpanda.com,namespace=default,resources=redpandas,verbs=get;list;watch;create;update;patch;delete
Expand Down

0 comments on commit 5e7e2e7

Please sign in to comment.