GPU-Live/event-exporter/test.yaml

66 lines
2.4 KiB
YAML

apiVersion: v1
kind: ConfigMap
metadata:
name: event-exporter-cfg
namespace: monitoring
data:
config.yaml: |
logLevel: warn
logFormat: json
metricsNamePrefix: event_exporter_
route:
routes:
- match:
- receiver: "dump"
- match:
- kind: "Pod|Deployment|ReplicaSet"
namespace: "org.*"
type: "Normal"
receiver: "my-dooray-Normal"
- match:
- kind: "Pod|Deployment|ReplicaSet"
namespace: "org.*"
type: "Warning"
receiver: "my-dooray-Warning"
receivers:
- name: "dump"
stdout: {}
- name: "my-dooray-Normal"
webhook:
endpoint: "https://nhnent.dooray.com/services/3407365765389747827/4142374041543123369/IxIWPFPMRzG37T-EMU_QMQ"
headers:
Content-Type: "application/json"
layout:
botName: "K8s Event Bot"
botIconImage: "https://static.dooray.com/static_images/dooray-bot.png"
text: "[{{ .Type }}] {{ .Namespace }}/{{ .InvolvedObject.Kind }}/{{ .InvolvedObject.Name }}"
attachments:
- title: "Information"
text: "{{ index .InvolvedObject.Labels \"project-name\" }}/{{ index .InvolvedObject.Labels \"workload-name\" }}"
color: "green"
- title: "Reason"
text: "{{ .Reason }}"
color: "green"
- title: "Message"
text: "{{ .Message }}"
color: "green"
- name: "my-dooray-Warning"
webhook:
endpoint: "https://nhnent.dooray.com/services/3407365765389747827/4142374041543123369/IxIWPFPMRzG37T-EMU_QMQ"
headers:
Content-Type: "application/json"
layout:
botName: "K8s Event Bot"
botIconImage: "https://static.dooray.com/static_images/dooray-bot.png"
text: "[{{ .Type }}] {{ .Namespace }}/{{ .InvolvedObject.Kind }}/{{ .InvolvedObject.Name }}"
attachments:
- title: "Information"
text: "{{ index .InvolvedObject.Labels \"project-name\" }}/{{ index .InvolvedObject.Labels \"workload-name\" }}"
color: "red"
- title: "Reason"
text: "{{ .Reason }}"
color: "red"
- title: "Message"
text: "{{ .Message }}"
color: "red"