Trying to figure out matchlabels for application-monitoring?
This commit is contained in:
parent
110786d513
commit
283d8a9dd3
3 changed files with 9 additions and 3 deletions
|
@ -19,7 +19,10 @@
|
|||
|
||||
post_tasks:
|
||||
- name: Apply node labels
|
||||
command: oc label --overwrite namespace application-monitoring monitoring-key=middleware
|
||||
command: oc label --overwrite namespace application-monitoring monitoring-key=cpe
|
||||
|
||||
- name: Apply node labels for bodhi POC
|
||||
command: oc label --overwrite namespace bodhi monitoring-key=cpe
|
||||
|
||||
- name: Copy files
|
||||
copy: src={{roles_path}}/openshift-apps/application-monitoring/files/ dest=/etc/openshift_apps/application-monitoring/
|
||||
|
|
|
@ -7,9 +7,12 @@ metadata:
|
|||
spec:
|
||||
replicas: 2
|
||||
serviceAccountName: prometheus
|
||||
serviceMonitorNamespaceSelector:
|
||||
matchLabels:
|
||||
monitoring-key: cpe
|
||||
serviceMonitorSelector:
|
||||
matchLabels:
|
||||
team: frontend
|
||||
monitoring-key: cpe
|
||||
alerting:
|
||||
alertmanagers:
|
||||
- namespace: application-monitoring
|
||||
|
|
|
@ -2,7 +2,7 @@ apiVersion: monitoring.coreos.com/v1
|
|||
kind: ServiceMonitor
|
||||
metadata:
|
||||
labels:
|
||||
monitoring-key: 'middleware'
|
||||
monitoring-key: 'cpe'
|
||||
name: bodhi-web
|
||||
spec:
|
||||
endpoints:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue