configure rbac for tbrntmon
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Tobias Brunner 2020-07-11 20:18:39 +02:00
parent f2e25b8fc6
commit 7aae6140eb
3 changed files with 30 additions and 7 deletions

View file

@ -6,14 +6,8 @@ metadata:
name: tbrntmon
namespace: tbrntmon
spec:
alerting:
alertmanagers:
- name: alertmanager-main
namespace: monitoring
port: web
externalUrl: http://prometheus-k8s.monitoring:9090
image: quay.io/prometheus/prometheus:v2.19.2
version: v2.17.2
version: v2.19.2
podMonitorNamespaceSelector:
matchLabels:
name: tbrntmon

16
tbrntmon/role.yaml Normal file
View file

@ -0,0 +1,16 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: prometheus-tbrntmon
namespace: tbrntmon
rules:
- apiGroups:
- ""
resources:
- services
- endpoints
- pods
verbs:
- get
- list
- watch

13
tbrntmon/rolebinding.yaml Normal file
View file

@ -0,0 +1,13 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: prometheus-tbrntmon
namespace: tbrntmon
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: prometheus-tbrntmon
subjects:
- kind: ServiceAccount
name: prometheus-tbrntmon
namespace: tbrntmon