Skip to content

Commit 6fa81ff

Browse files
PeterYurkovichjgbernalp
authored andcommitted
feature: update perses to include rbac
Signed-off-by: Gabriel Bernal <gbernal@redhat.com>
1 parent 1f89cec commit 6fa81ff

25 files changed

+1625
-651
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ generate-prom-operator-crds: $(CONTROLLER_GEN)
6060
.PHONY: generate-perses-op-crds
6161
generate-perses-op-crds: $(CONTROLLER_GEN)
6262
$(CONTROLLER_GEN) crd \
63-
paths=github.com/perses/perses-operator/api/... \
63+
paths=github.com/rhobs/perses-operator/api/... \
6464
output:dir=. \
6565
output:crd:dir=./deploy/perses/crds
6666

bundle/manifests/observability-operator.clusterserviceversion.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ metadata:
4242
categories: Monitoring
4343
certified: "false"
4444
containerImage: observability-operator:1.2.0
45-
createdAt: "2025-05-30T13:08:57Z"
45+
createdAt: "2025-06-13T09:25:15Z"
4646
description: A Go based Kubernetes operator to setup and manage highly available
4747
Monitoring Stack using Prometheus, Alertmanager and Thanos Querier.
4848
operatorframework.io/cluster-monitoring: "true"
@@ -923,7 +923,7 @@ spec:
923923
- --images=alertmanager=quay.io/prometheus/alertmanager:v0.26.0
924924
- --images=prometheus=quay.io/prometheus/prometheus:v2.49.1
925925
- --images=thanos=quay.io/thanos/thanos:v0.33.0
926-
- --images=perses=quay.io/persesdev/perses:v0.50.3
926+
- --images=perses=quay.io/openshift-observability-ui/perses:v0.51-go-1.23
927927
env:
928928
- name: NAMESPACE
929929
valueFrom:
@@ -1000,7 +1000,7 @@ spec:
10001000
operator: Exists
10011001
weight: 1
10021002
containers:
1003-
- image: quay.io/persesdev/perses-operator:v0.1.12
1003+
- image: quay.io/openshift-observability-ui/perses-operator:v0.2-go-1.23
10041004
livenessProbe:
10051005
httpGet:
10061006
path: /healthz
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
apiVersion: rbac.authorization.k8s.io/v1
2+
kind: ClusterRole
3+
metadata:
4+
creationTimestamp: null
5+
name: perses-auth-delegator
6+
rules:
7+
- apiGroups:
8+
- authentication.k8s.io
9+
resources:
10+
- tokenreviews
11+
verbs:
12+
- create
13+
- apiGroups:
14+
- authorization.k8s.io
15+
resources:
16+
- subjectaccessreviews
17+
verbs:
18+
- create

bundle/manifests/perses.dev_perses.yaml

Lines changed: 557 additions & 241 deletions
Large diffs are not rendered by default.

bundle/manifests/perses.dev_persesdashboards.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ spec:
1212
kind: PersesDashboard
1313
listKind: PersesDashboardList
1414
plural: persesdashboards
15+
shortNames:
16+
- perdb
1517
singular: persesdashboard
1618
scope: Namespaced
1719
versions:

bundle/manifests/perses.dev_persesdatasources.yaml

Lines changed: 104 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ spec:
1212
kind: PersesDatasource
1313
listKind: PersesDatasourceList
1414
plural: persesdatasources
15+
shortNames:
16+
- perds
1517
singular: persesdatasource
1618
scope: Namespaced
1719
versions:
@@ -41,6 +43,96 @@ spec:
4143
properties:
4244
client:
4345
properties:
46+
basicAuth:
47+
description: BasicAuth basic auth config for perses client
48+
properties:
49+
name:
50+
description: Name of basic auth k8s resource (when type is
51+
secret or configmap)
52+
type: string
53+
namespace:
54+
description: Namsespace of certificate k8s resource (when
55+
type is secret or configmap)
56+
type: string
57+
password_path:
58+
description: Path to password
59+
type: string
60+
type:
61+
description: Type source type of secret
62+
enum:
63+
- secret
64+
- configmap
65+
- file
66+
type: string
67+
username:
68+
description: Username for basic auth
69+
type: string
70+
required:
71+
- password_path
72+
- type
73+
- username
74+
type: object
75+
kubernetesAuth:
76+
description: KubernetesAuth configuration for perses client
77+
properties:
78+
enable:
79+
description: Enable kubernetes auth for perses client
80+
type: boolean
81+
required:
82+
- enable
83+
type: object
84+
oauth:
85+
description: OAuth configuration for perses client
86+
properties:
87+
authStyle:
88+
description: |-
89+
AuthStyle optionally specifies how the endpoint wants the
90+
client ID & client secret sent. The zero value means to
91+
auto-detect.
92+
type: integer
93+
clientIDPath:
94+
description: Path to client id
95+
type: string
96+
clientSecretPath:
97+
description: Path to client secret
98+
type: string
99+
endpointParams:
100+
additionalProperties:
101+
items:
102+
type: string
103+
type: array
104+
description: EndpointParams specifies additional parameters
105+
for requests to the token endpoint.
106+
type: object
107+
name:
108+
description: Name of basic auth k8s resource (when type is
109+
secret or configmap)
110+
type: string
111+
namespace:
112+
description: Namsespace of certificate k8s resource (when
113+
type is secret or configmap)
114+
type: string
115+
scopes:
116+
description: Scope specifies optional requested permissions.
117+
items:
118+
type: string
119+
type: array
120+
tokenURL:
121+
description: |-
122+
TokenURL is the resource server's token endpoint
123+
URL. This is a constant specific to each server.
124+
type: string
125+
type:
126+
description: Type source type of secret
127+
enum:
128+
- secret
129+
- configmap
130+
- file
131+
type: string
132+
required:
133+
- tokenURL
134+
- type
135+
type: object
44136
tls:
45137
description: TLS the equivalent to the tls_config for perses client
46138
properties:
@@ -51,14 +143,18 @@ spec:
51143
description: Path to Certificate
52144
type: string
53145
name:
54-
description: Name of certificate k8s resource (when type
146+
description: Name of basic auth k8s resource (when type
55147
is secret or configmap)
56148
type: string
149+
namespace:
150+
description: Namsespace of certificate k8s resource (when
151+
type is secret or configmap)
152+
type: string
57153
privateKeyPath:
58154
description: Path to Private key certificate
59155
type: string
60156
type:
61-
description: Type source type of certificate
157+
description: Type source type of secret
62158
enum:
63159
- secret
64160
- configmap
@@ -81,14 +177,18 @@ spec:
81177
description: Path to Certificate
82178
type: string
83179
name:
84-
description: Name of certificate k8s resource (when type
180+
description: Name of basic auth k8s resource (when type
85181
is secret or configmap)
86182
type: string
183+
namespace:
184+
description: Namsespace of certificate k8s resource (when
185+
type is secret or configmap)
186+
type: string
87187
privateKeyPath:
88188
description: Path to Private key certificate
89189
type: string
90190
type:
91-
description: Type source type of certificate
191+
description: Type source type of secret
92192
enum:
93193
- secret
94194
- configmap
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
apiVersion: rbac.authorization.k8s.io/v1
2+
kind: ClusterRoleBinding
3+
metadata:
4+
creationTimestamp: null
5+
labels:
6+
app.kubernetes.io/component: controller
7+
app.kubernetes.io/name: perses
8+
name: perses
9+
roleRef:
10+
apiGroup: rbac.authorization.k8s.io
11+
kind: ClusterRole
12+
name: perses-auth-delegator
13+
subjects:
14+
- kind: ServiceAccount
15+
name: perses
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
apiVersion: v1
2+
kind: ServiceAccount
3+
metadata:
4+
creationTimestamp: null
5+
name: perses

cmd/operator/main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ var defaultImages = map[string]string{
5050
"health-analyzer": "quay.io/openshiftanalytics/cluster-health-analyzer:v0.5.0",
5151
"ui-monitoring-pf5": "quay.io/openshift-observability-ui/monitoring-console-plugin:v0.4.0",
5252
"ui-monitoring": "quay.io/openshift-observability-ui/monitoring-console-plugin:v0.5.0",
53-
"perses": "quay.io/persesdev/perses:v0.50.3",
53+
"perses": "quay.io/openshift-observability-ui/perses:v0.51-go-1.23",
5454
}
5555

5656
func imagesUsed() []string {

deploy/operator/kustomization.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ patches:
4141
- patch: |-
4242
- op: add
4343
path: /spec/template/spec/containers/0/args/-
44-
value: --images=perses=quay.io/persesdev/perses:v0.50.3
44+
value: --images=perses=quay.io/openshift-observability-ui/perses:v0.51-go-1.23
4545
target:
4646
group: apps
4747
kind: Deployment

0 commit comments

Comments
 (0)